summaryrefslogtreecommitdiff
path: root/Git
Commit message (Collapse)AuthorAge
* use --literal-pathspecs globally, as a better way to avoid globbingGravatar Joey Hess2015-03-30
| | | | | | | | This might be overkill; I only know I need it in ls-files, but other git commands can also do their own globbing, it turns out, and I am pretty sure I never want them too when git-annex is using them as plumbing. Test suite still passes and it looks ok.
* workaround git ls-files bug in handling slash-escaped wildcardsGravatar Joey Hess2015-03-30
| | | | | | | | | | | There's no good solution for git-annex here; I can't escape or un-escape and avoid breaking in some cases, so I've chosen the combo least likely to result in breakage. Git really needs to fix its behavior here. The only other thing git-annex could do is treat this as a feature, and don't try to escape at all. Ugh.
* Prevent git-ls-files from double-expanding wildcards when an unexpanded ↵Gravatar Joey Hess2015-03-27
| | | | | | | | | | wildcard is passed to a git-annex command like add or find. Note that previously, `git annex find *.jpg` would find eg, foo/bar.jpg. That was never intended or documented behavior, so I'm going to change it. But this is potentially a behavior change if someone discovered that behavior and relied on it despite it being accidental. Oh well.. can't make an omlette w/o breaking some eggs.
* promote forum request to todo item so it is not lostGravatar Joey Hess2015-03-27
|
* Improve error message when --in @date is used and there is no reflog for the ↵Gravatar Joey Hess2015-03-26
| | | | git-annex branch.
* sync: Fix committing when in a direct mode repo that has no HEAD ref.Gravatar Joey Hess2015-03-04
| | | | | | | | Seen for example, a newly checked out git submodule. In this case, .git/HEAD is a raw sha, rather than the usual reference to a ref. Removed currentSha in passing, since it was a more roundabout way of doing what headSha does, and headSha is more robust.
* Submodules are now supported by git-annex!Gravatar Joey Hess2015-03-02
| | | | | | | | | | | | | | | | | | Seems to work, but still experimental until it's been tested more. When repositories are on filesystems not supporting symlinks, the .git dir symlink trick cannot be used. Since we're going to be in direct mode anyway, the .git dir symlink is not strictly needed. However, I have not fixed the code that creates new annex symlinks to handle this case -- the committed symlinks will be wrong. git annex sync happens to currently fail in a submodule using direct mode, because there's no HEAD ref. That also needs to be dealt with to get this fully working in crippled filesystems. Leaving http://github.com/datalad/datalad/issues/44 open until these issues are dealt with.
* add -q to git symbolic-ref callGravatar Joey Hess2015-03-02
| | | | | | | | | | | Avoids a warning message from git when HEAD doesn't exist. Which it won't when eg, git-annex is used in a submodule just cloned with git clone --recursive. In this case, a specific ref is checked out and there's no HEAD yet. The code already returned Nothing in this case, so no behavior change other than not showing the warning. And git-annex operates fine in this situation.
* avoid unncessary IOGravatar Joey Hess2015-02-12
|
* update my email address and homepage urlGravatar Joey Hess2015-01-21
|
* Windows: Fix running of the pre-commit-annex hook.Gravatar Joey Hess2015-01-20
|
* convert parentDir to be based on takeDirectory, but fixed for trailing /Gravatar Joey Hess2015-01-09
|
* revert parentDir changeGravatar Joey Hess2015-01-09
| | | | | | | | Reverts 2bba5bc22d049272d3328bfa6c452d3e2e50e86c Unfortunately, this caused breakage on Windows, and possibly elsewhere, because parentDir and takeDirectory do not behave the same when there is a trailing directory separator.
* Merge branch 'master' into relativepathsGravatar Joey Hess2015-01-06
|\
| * Bugfix: A file named HEAD in the work tree could confuse some git commands ↵Gravatar Joey Hess2015-01-06
| | | | | | | | run by git-annex.
* | Merge branch 'master' into relativepathsGravatar Joey Hess2015-01-06
|\| | | | | | | | | | | Conflicts: Locations.hs debian/changelog
| * made parentDir return a Maybe FilePath; removed most uses of itGravatar Joey Hess2015-01-06
| | | | | | | | | | | | | | | | parentDir is less safe than takeDirectory, especially when working with relative FilePaths. It's really only useful in loops that want to terminate at / This commit was sponsored by Audric SCHILTKNECHT.
* | git-hash-object needs absolute files (git bug)Gravatar Joey Hess2015-01-06
| | | | | | | | | | A relative path to a file makes it fail. I am pretty sure this is a git bug; workaround it.
* | git repo path may be relative, so don't assume absolute any moreGravatar Joey Hess2015-01-06
| | | | | | | | Fixes 6 test failures.
* | Switch to using relative paths to the git repository.Gravatar Joey Hess2015-01-06
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | This allows the git repository to be moved while git-annex is running in it, with fewer problems. On Windows, this avoids some of the problems with the absurdly small MAX_PATH of 260 bytes. In particular, git-annex repositories should work in deeper/longer directory structures than before. See http://git-annex.branchable.com/bugs/__34__git-annex:_direct:_1_failed__34___on_Windows/ There are several possible ways this change could break git-annex: 1. If it changes its working directory while it's running, that would be Bad News. Good news everyone! git-annex never does so. It would also break thread safety, so all such things were stomped out long ago. 2. parentDir "." -> "" which is not a valid path. I had to fix one instace of this, and I should probably wipe all calls to parentDir out of the git-annex code base; it was never a good idea. 3. Things like relPathDirToFile require absolute input paths, and code assumes that the git repo path is absolute and passes it to it as-is. In the case of relPathDirToFile, I converted it to not make this assumption. Currently, the test suite has 16 failures.
* Check git version at runtime, rather than assuming it will be the same as ↵Gravatar Joey Hess2015-01-05
| | | | | | | | | | | | | | | | | the git version used at build time when running git-checkattr and git-branch remove. It's ok to probe every time for git-branch remove because that's run quite rarely. For git-checkattr, it's run only once, when starting the --batch mode, and so again the overhead is pretty minimal. This leaves 2 places where the build version is still used. git merge might be interactive or fail if one skews, and --no-gpg-sign might not be pased, or might be passed to a git that doesn't understand it if the other skews. It seems a little expensive to check the git version each time these are used. This doesn't seem likely to cause many problems, at least compared with check-attr hanging on skew.
* split out DiffTreeItemGravatar Joey Hess2014-12-22
| | | | This makes github-backup happier when it reuses this library.
* Use wget -q --show-progress for less verbose wget output, when built with ↵Gravatar Joey Hess2014-12-16
| | | | wget 1.16.
* undo commandGravatar Joey Hess2014-11-14
| | | | This commit was sponsored by Andrew Cant.
* simplifyGravatar Joey Hess2014-11-12
|
* proxy: for all your direct mode repository munging needsGravatar Joey Hess2014-11-12
| | | | | | | This allows bypassing the direct mode guard in a safe way to do all sorts of things including git revert, git mv, git checkout ... This commit was sponsored by the WikiMedia Foundation.
* comment typoGravatar Joey Hess2014-11-10
|
* pre-commit: Block partial commit of unlocked annexed file, since that left a ↵Gravatar Joey Hess2014-11-10
| | | | | | | | | | | | typechange staged in index I had hoped that the git devs could change git's handling of partial commits to not use a false index file, but seems not. So, this relies on some git internals to detect that case. The test suite has a test case added to catch it if changes to git break it. This commit was sponsored by Paul Tagliamonte.
* move remote removal into separate moduleGravatar Joey Hess2014-10-27
| | | | | | This allows using Git.Remote w/o needing to have Git.BuildVersion, which requires configure. It will simplify github-backup when these libraries are used there.
* Use haskell setenv library to clean up several ugly workarounds for ↵Gravatar Joey Hess2014-10-15
| | | | | | | | | inability to manipulate the environment on windows. Didn't know that this library existed! This includes making git-annex not re-exec itself on start on windows, and making the test suite on Windows run tests without forking.
* repair: Prevent auto gc from happening when fetching from a remote.Gravatar Joey Hess2014-10-12
|
* indent with tabs not spacesGravatar Joey Hess2014-10-09
| | | | | | | | | | | Found these with: git grep "^ " $(find -type f -name \*.hs) |grep -v ': where' Unfortunately there is some inline hamlet that cannot use tabs for indentation. Also, Assistant/WebApp/Bootstrap3.hs is a copy of a module and so I'm leaving it as-is.
* fix some mixed space+tab indentationGravatar Joey Hess2014-10-09
| | | | | | | | | This fixes all instances of " \t" in the code base. Most common case seems to be after a "where" line; probably vim copied the two space layout of that line. Done as a background task while listening to episode 2 of the Type Theory podcast.
* Fix parsing of ipv6 address in git remote address when it was not formatted ↵Gravatar Joey Hess2014-09-10
| | | | as an url.
* New annex.hardlink setting. Closes: #758593Gravatar Joey Hess2014-09-05
| | | | | | | | | | * New annex.hardlink setting. Closes: #758593 * init: Automatically detect when a repository was cloned with --shared, and set annex.hardlink=true, as well as marking the repository as untrusted. Had to reorganize Logs.Trust a bit to avoid a cycle between it and Annex.Init.
* Fix handing of autocorrection when running outside a git repository.Gravatar Joey Hess2014-08-23
| | | | | | Old behavior was to take the first fuzzy match. Now, it checks the globa git config, and runs the normal fuzzy handling, including failing to run a semi-random command by default.
* unify exception handling into Utility.ExceptionGravatar Joey Hess2014-08-07
| | | | | | | | | | | | | | | | | | | | Removed old extensible-exceptions, only needed for very old ghc. Made webdav use Utility.Exception, to work after some changes in DAV's exception handling. Removed Annex.Exception. Mostly this was trivial, but note that tryAnnex is replaced with tryNonAsync and catchAnnex replaced with catchNonAsync. In theory that could be a behavior change, since the former caught all exceptions, and the latter don't catch async exceptions. However, in practice, nothing in the Annex monad uses async exceptions. Grepping for throwTo and killThread only find stuff in the assistant, which does not seem related. Command.Add.undo is changed to accept a SomeException, and things that use it for rollback now catch non-async exceptions, rather than only IOExceptions.
* improve repair of bad branchesGravatar Joey Hess2014-07-21
| | | | | | | | | | | | | | | The repair code assumed that if fsck found no broken objects, after removing bad objects and possibly pulling replacements from remote, all was well.. but this is not really true. Removing bad objects could leave some branches broken. fsck doesn't report any missing objects in this case, and its messages about broken branches are ignored by the fsck output parser. To deal with this, added a separate scan of all refs to find broken ones and remove them when --forced. This will also let anyone who ran into this bug run repair again to fix up the incomplete repair done before. This commit was sponsored by Aaron Whitehouse.
* Set gcrypt-publish-participants when setting up a gcrypt repository, to ↵Gravatar Joey Hess2014-07-15
| | | | | | | | | | | | | avoid unncessary passphrase prompts. This is a security/usability tradeoff. To avoid exposing the gpg key ids who can decrypt the repository, users can unset gcrypt-publish-participants. The gcrypt-publish-participants option is available in my fork of git-remote-gcrypt. This commit was sponsored by Christopher Kernahan.
* Fix git version that supported --no-gpg-sign.Gravatar Joey Hess2014-07-08
| | | | | This is weird, git describe said the commit landed in 1.8.5, but 1.9.3 does not have it on OSX. Assume 2.0.0.
* avoid using --no-gpg-sign with old versions of gitGravatar Joey Hess2014-07-04
| | | | and refactor some
* reorgGravatar Joey Hess2014-07-04
| | | | | | avoid Git.Command needing Utility.Batch which needs async For github-backup etc
* support commit.gpgsignGravatar Joey Hess2014-07-04
| | | | | | | | | | | | | | | | | | | | | Support users who have set commit.gpgsign, by disabling gpg signatures for git-annex branch commits and commits made by the assistant. The thinking here is that a user sets commit.gpgsign intending the commits that they manually initiate to be gpg signed. But not commits made in the background, whether by a deamon or implicitly to the git-annex branch. gpg signing those would be at best a waste of CPU and at worst would fail, or flood the user with gpg passphrase prompts, or put their signature on changes they did not directly do. See Debian bug #753720. Also makes all commits done by git-annex go through a few central control points, to make such changes easier in future. Also disables commit.gpgsign in the test suite. This commit was sponsored by Antoine Boegli.
* Fix bug in annex.queuesize calculation that caused much more queue flushing ↵Gravatar Joey Hess2014-06-18
| | | | | | | | than necessary. The bug caused the size of the queue to be miscalculted; it was doubled each time an item was added. Commands run after approx 140 items rather than the intended 10240!
* fix a test suite reversion on WindowsGravatar Joey Hess2014-06-12
| | | | Forgot to pass gitEnv when running commands in the git queue on windows.
* export CreateProcess fields from Utility.ProcessGravatar Joey Hess2014-06-10
| | | | update code to avoid cwd and env redefinition warnings
* avoid bad commits after interrupted direct mode sync (or merge)Gravatar Joey Hess2014-06-09
| | | | | | | | | | | | | | | It was possible for a interrupted sync or merge in direct mode to leave the work tree out of sync with the last recorded commit. This would result in the next commit seeing files missing from the work tree, and committing their removal. Now, a direct mode merge happens not only in a throwaway work tree, but using a temporary index file, and without any commits or index changes being made until the real work tree has been updated. If the merge is interrupted, the work tree may have some updated files, but worst case a commit will redundantly commit changes that come from the merge. This commit was sponsored by Tony Cantor.
* Merge branch 'master' into remotecontrolGravatar Joey Hess2014-04-14
|\ | | | | | | | | Conflicts: doc/devblog/day_152__more_ssh_connection_caching.mdwn
| * adjust to not use cpp in modules used by configureGravatar Joey Hess2014-04-14
| |
* | support gcrypt remotes (assuming them to be over ssh transport)Gravatar Joey Hess2014-04-08
|/