Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-03-24iterators: refactored tree iteratorEdward Thomson
Refactored the tree iterator to never recurse; simply process the next entry in order in `advance`. Additionally, reduce the number of allocations and sorting as much as possible to provide a ~30% speedup on case-sensitive iteration. (The gains for case-insensitive iteration are less majestic.)
2016-03-24repo::iterator: don't go out of boundsEdward Thomson
2016-03-24iterator: disambiguate reset and reset_rangeEdward Thomson
Disambiguate the reset and reset_range functions. Now reset_range with a NULL path will clear the start or end; reset will leave the existing start and end unchanged.
2016-02-12Horrible fix for #3173.Arthur Schreiber
2015-12-27git_repository_init: include dotfiles when copying templatesEdward Thomson
Include dotfiles when copying template directory, which will handle both a template directory itself that begins with a dotfile, and any dotfiles inside the directory.
2015-12-27repo::init tests: test a template dir with leading dotEdward Thomson
Ensure that we can handle template directories that begin with a leading dot.
2015-12-27repo::init tests: test init.templatedir settingEdward Thomson
Ensure that `git_repository_init` honors the `init.templatedir` configuration setting.
2015-11-20repository: distinguish sequencer cherry-pick and revertCarlos Martín Nieto
These are not quite like their plain counterparts and require special handling.
2015-09-21Merge pull request #3434 from ethomson/reservednamesCarlos Martín Nieto
Win32 Reserved names: don't reserve names outside the working directory
2015-09-18repo::reservedname: test a submodule updateEdward Thomson
Test an initial submodule update, where we are trying to checkout the submodule for the first time, and placing a file within the submodule working directory with the same name as the submodule (and consequently, the same name as the repository itself).
2015-09-17git_futils_mkdir_*: make a relative-to-base mkdirEdward Thomson
Untangle git_futils_mkdir from git_futils_mkdir_ext - the latter assumes that we own everything beneath the base, as if it were being called with a base of the repository or working directory, and is tailored towards checkout and ensuring that there is no bogosity beneath the base that must be cleaned up. This is (at best) slow and (at worst) unsafe in the larger context of a filesystem where we do not own things and cannot do things like unlink symlinks that are in our way.
2015-08-31iterator test: handle case (in)sensitivityEdward Thomson
2015-08-31iterator test: use new iter opts in fifo testEdward Thomson
2015-08-31iterator: saner pathlist matching for idx iteratorEdward Thomson
Some nicer refactoring for index iteration walks. The index iterator doesn't binary search through the pathlist space, since it lacks directory entries, and would have to binary search each index entry and all its parents (eg, when presented with an index entry of `foo/bar/file.c`, you would have to look in the pathlist for `foo/bar/file.c`, `foo/bar` and `foo`). Since the index entries and the pathlist are both nicely sorted, we walk the index entries in lockstep with the pathlist like we do for other iteration/diff/merge walks.
2015-08-31tree_iterator: use a pathlistEdward Thomson
2015-08-31diff: use new iterator pathlist handlingEdward Thomson
When using literal pathspecs in diff with `GIT_DIFF_DISABLE_PATHSPEC_MATCH` turn on the faster iterator pathlist handling. Updates iterator pathspecs to include directory prefixes (eg, `foo/`) for compatibility with `GIT_DIFF_DISABLE_PATHSPEC_MATCH`.
2015-08-29iterator: sort subdirs properly with pathlistEdward Thomson
When given a pathlist, don't assume that directories sort before files. Walk through any list of entries sorting before us to make sure that we've exhausted all entries that *aren't* directories. Eg, if we're searching for 'foo/bar', and we have a 'foo.c', keep advancing the pathlist to keep looking for an entry prefixed with 'foo/'.
2015-08-29Move filelist into the iterator handling itself.Edward Thomson
2015-08-29iterator: use an options struct instead of argsEdward Thomson
2015-07-27iterator: adjust unreadable-dir test to new behaviourCarlos Martín Nieto
We don't want the iterator to make us stop whenever we hit an unreadable dir. We should instead move over to the next item.
2015-07-02git__getenv: utf-8 aware env readerEdward Thomson
Introduce `git__getenv` which is a UTF-8 aware `getenv` everywhere. Make `cl_getenv` use this to keep consistent memory handling around return values (free everywhere, as opposed to only some platforms).
2015-06-24Fixed Xcode 6.1 build warningsPierre-Olivier Latour
2015-06-23repository: check the format versionCarlos Martín Nieto
This is something we do on re-init but not when opening a repository. This hasn't particularly mattered up to now as the version has been 0 ever since the first release of git, but the times, they're a-changing and we will soon see version 1 in the wild. We need to make sure we don't open those.
2015-03-18Merge remote-tracking branch 'ethomson/submodule_8dot3'Carlos Martín Nieto
2015-03-16Add tests for the annotated versions of ref-modifying functionsCarlos Martín Nieto
This also brings the soft-reset tests back to life. The function name was missing an underscore, meaning they had not been running.
2015-03-10repository_new: test its barenessEdward Thomson
2015-03-03config: borrow refcounted referencesCarlos Martín Nieto
This changes the get_entry() method to return a refcounted version of the config entry, which you have to free when you're done. This allows us to avoid freeing the memory in which the entry is stored on a refresh, which may happen at any time for a live config. For this reason, get_string() has been forbidden on live configs and a new function get_string_buf() has been added, which stores the string in a git_buf which the user then owns. The functions which parse the string value takea advantage of the borrowing to parse safely and then release the entry.
2015-03-03repository: remove log message override for switching the active branchCarlos Martín Nieto
We want to use the "checkout: moving from ..." message in order to let git know when a change of branch has happened. Make the convenience functions for this goal write this message.
2015-03-03Remove the signature from ref-modifying functionsCarlos Martín Nieto
The signature for the reflog is not something which changes dynamically. Almost all uses will be NULL, since we want for the repository's default identity to be used, making it noise. In order to allow for changing the identity, we instead provide git_repository_set_ident() and git_repository_ident() which allow a user to override the choice of signature.
2015-02-27repository: Introduce "reserved names"Edward Thomson
A repository can have multiple "reserved names" now, not just a single "short name" for the repository folder itself. Refactor to include a git_repository__reserved_names that returns all the reserved names for a repository.
2015-02-19tests: separate INVASIVE filesystem testsEdward Thomson
Introduce GITTEST_INVASIVE_FS_STRUCTURE for things that are invasive to your filesystem structure (like creating folders at your filesystem root) and GITTEST_INVASIVE_FS_SIZE for things that write lots of data.
2015-02-12Merge pull request #2866 from ethomson/checkout_perf2Carlos Martín Nieto
Checkout performance
2015-02-05repo: ensure we can create repo at filesystem rootEdward Thomson
Test to ensure that we can create a repository at the filesystem root. Introduces a new test environment variable, `GITTEST_INVASIVE_FILESYSTEM` for tests that do terrible things like escaping the clar sandbox and writing to the root directory. It is expected that the CI builds will enable this but that normal people would not want this.
2015-02-03tests: update for new test dataEdward Thomson
2015-01-08repo::init test: create hook symlinkEdward Thomson
Remove the hook symlink from the test resources, so that we can have a source tree that is easy to zip up and copy around on systems that don't support symlinks. Create it dynamically at test execution instead.
2014-12-27treebuilder: rename _create() to _new()Carlos Martín Nieto
This function is a constructor, so let's name it like one and leave _create() for the reference functions, which do create/write the reference.
2014-12-17treebuilder: take a repository for path validationEdward Thomson
Path validation may be influenced by `core.protectHFS` and `core.protectNTFS` configuration settings, thus treebuilders can take a repository to influence their configuration.
2014-11-08remote: rename _load() to _lookup()Carlos Martín Nieto
This brings it in line with the rest of the lookup functions.
2014-11-07iterator: submodules are determined by an index or treeCarlos Martín Nieto
We cannot know from looking at .gitmodules whether a directory is a submodule or not. We need the index or tree we are comparing against to tell us. Otherwise we have to assume the entry in .gitmodules is stale or otherwise invalid. Thus we pass the index of the repository into the workdir iterator, even if we do not want to compare against it. This follows what git does, which even for `git diff <tree>`, it will consider staged submodules as such.
2014-09-17Clean up some leaks in the test suiteCarlos Martín Nieto
2014-09-03Introduce option to use relative paths for repository work directoryJameson Miller
Teach git_repository_init_ext to use relative paths for the gitlink to the work directory. This is used when creating a sub repository where the sub repository resides in the parent repository's .git directory.
2014-08-09Don't report status on named pipesRussell Belfer
Git skips entries in directories that are not S_ISDIR, S_ISREG, or S_ISLNK, so let's make libgit2 do the same thing.
2014-07-22git_cherry_pick -> git_cherrypickEdward Thomson
2014-07-01Introduce cl_assert_equal_oidEdward Thomson
2014-05-27Fix compile error on Visual StudioCha, Hojeong
2014-05-15Better search path sandboxingRussell Belfer
There are a number of tests that modify the global or system search paths during the tests. This adds a helper function to make it easier to restore those paths and makes sure that they are getting restored in a manner that preserves test isolation.
2014-04-12Correct C90 warningsJacques Germishuys
2014-04-07git_repository_state_cleanup() should remove rebase-merge/, rebase-apply/ ↵Jacques Germishuys
and BISECT_LOG
2014-03-19reflog: handle symref chainsCarlos Martín Nieto
Given HEAD -> master -> foo, when updating foo's reflog we should also update HEAD's, as it's considered the current branch.
2014-03-19reflog: handle the birth of a branchCarlos Martín Nieto
The reflog append function was overzealous in its checking. When passed an old and new ids, it should not do any checking, but just serialize the data to a reflog entry.