aboutsummaryrefslogtreecommitdiff
path: root/Utility
Commit message (Collapse)AuthorAge
* fix build failureGravatar Joey Hess2015-01-09
|
* Merge branch 'master' into relativepathsGravatar Joey Hess2015-01-06
|\ | | | | | | | | | | Conflicts: Locations.hs debian/changelog
| * build fixGravatar Joey Hess2015-01-06
| |
| * 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.
* | 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.
* Fix build with process 1.2.1.0.Gravatar Joey Hess2015-01-04
|
* OSX: Switched away from deprecated statfs64 interface.Gravatar Joey Hess2014-12-31
| | | | | | | | | | Getting rid of build warning warning: 'statfs64' is deprecated: first deprecated in OS X 10.6 [-Wdeprecated-declarations] 10.6 is much older than the oldest git-annex OSX port, so won't break anything.
* Windows: Got the rsync special remote working.Gravatar Joey Hess2014-12-30
| | | | | | | | | More aggressive rsync params fixup for windows. Param may contain a url, or a file path, so check if it looks like a local file path and if so, fix it up. On windows only, rsyncUrlIsPath will treat c:foo as a path, rather than as a rsyncurl starting with a host "c".
* Windows: Fix local rsync filepath munging (fixes 26 test suite failures).Gravatar Joey Hess2014-12-30
|
* final warning fixGravatar Joey Hess2014-12-29
|
* fixGravatar Joey Hess2014-12-29
|
* fix more warnings on BSD/OSXGravatar Joey Hess2014-12-29
|
* one more warningGravatar Joey Hess2014-12-29
|
* fixed all remaining build warnings on WindowsGravatar Joey Hess2014-12-29
|
* fix a OSX C compiler warning about null pointerGravatar Joey Hess2014-12-29
|
* fix OSX build warningGravatar Joey Hess2014-12-29
|
* Work around statfs() overflow on some XFS systems.Gravatar Joey Hess2014-12-23
| | | | | | statfs(".", 0xffa8ad50) = -1 EOVERFLOW (Value too large for defined data type) Ref <20141222221621.GO7251@onerussian.com>
* refactorGravatar Joey Hess2014-12-17
|
* Use wget -q --show-progress for less verbose wget output, when built with ↵Gravatar Joey Hess2014-12-16
| | | | wget 1.16.
* sanitize filepaths provided by checkUrlGravatar Joey Hess2014-12-11
|
* more general readProcess' merged from propellorGravatar Joey Hess2014-11-19
|
* Work around apparent bug in lsof 4.88's -F output format.Gravatar Joey Hess2014-11-12
|
* generalize monadsGravatar Joey Hess2014-11-12
|
* switch from hGetSome to hGetGravatar Joey Hess2014-11-03
| | | | | | | | | | | | | | This should be essentially no-op change for hGetContentsMetered, since it always gets the entire contents. So the only difference is that each chunk of the lazy bytestring will always be the full chunk size. So, I'm pretty sure this is safe. Also, the only current users of hGetContentsMetered are reading files, so the stream won't block for long in the middle. The improvement is that hGetUntilMetered will always get some multiple of the defaultChunkSize. This will allow the S3 multipart code to pick a fixed size and know that hGetUntilMetered will really get that size. (cherry picked from commit bd09046291a5fde26afc02f5838c6594c1fa9c00)
* hGetUntilMeteredGravatar Joey Hess2014-11-03
|
* Windows: Fix crash when user.name is not set in git config.Gravatar Joey Hess2014-10-31
|
* getUserEntryForID does not work on windowsGravatar Joey Hess2014-10-31
| | | | Throw an error instead, mentioning the relevant env vars.
* more accurate version boundsGravatar Joey Hess2014-10-24
|
* deal with yesod's second gratuitous rename of the same function in a yearGravatar Joey Hess2014-10-23
|
* typoGravatar Joey Hess2014-10-16
|
* typosGravatar Joey Hess2014-10-16
|
* 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.
* revert reversionGravatar Joey Hess2014-10-15
| | | | | | This reverts commit 05c37ced983e89505c2c3cdcbe1db67e3a86560b. Android build is going to have consistent versions again.
* unbreak android buildGravatar Joey Hess2014-10-14
| | | | | | | | This reverts commit cfc51c5e4ec04f9d5088c42922217cf90b63c903 and commit 78f94f50674d60c7d54307029bef1edf9b27782b. Those commits were fine, except the android autobuilder currently has a bit of a mess of yesod versions and broke. Better to wait on this.
* more accurate bounds on yesod boostrap3 ifdefsGravatar Joey Hess2014-10-13
|
* avoid using Assistant.WebApp.Bootstrap3 when building with current yesodGravatar Joey Hess2014-10-09
| | | | | | | Only use that when building with ancient yesod, which does not include it. This also let me remove ifdefs in the file to support building with the new version of yesod.
* 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.
* Windows: Avoid crashing trying to list gpg secret keys, for gcrypt which is ↵Gravatar Joey Hess2014-09-16
| | | | not yet supported on Windows.
* Rather than crashing when there's a problem with the requested bloomfilter ↵Gravatar Joey Hess2014-09-12
| | | | capacity/accuracy, fall back to a reasonable default bloom filter size.
* Do not preserve permissions and acls when copying files from one local git ↵Gravatar Joey Hess2014-08-26
| | | | | | | | | | | | | | | | | repository to another. Timestamps are still preserved as long as cp --preserve=timestamps is supported. This avoids cp -a overriding the default mode acls that the user might have set in a git repository. With GNU cp, this behavior change should not be a breaking change, because git-anex also uses rsync sometimes in the same situation, and has only ever preserved timestamps when using rsync. Systems without GNU cp will no longer use cp -a, but instead just cp. So, timestamps will no longer be preserved. Preserving timestamps when copying between repos is not guaranteed anyway. Closes: #729757
* fix imports for windowsGravatar Joey Hess2014-08-23
|
* final scary locking refactoring (for now)Gravatar Joey Hess2014-08-20
| | | | | | | | | | Note that while before checkTransfer this called getLock with WriteLock, getLockStatus's use of ReadLock will also notice any exclusive locks. Since transfer info files are only locked exclusively, never shared, there is no behavior change. Also, fixes checkLocked to actually return Just False when the file exists, but is not locked.
* more lock file refactoringGravatar Joey Hess2014-08-20
| | | | | | | | Also fixes a test suite failures introduced in recent commits, where inAnnexSafe failed in indirect mode, since it tried to open the lock file ReadWrite. This is why the new checkLocked opens it ReadOnly. This commit was sponsored by Chad Horohoe.
* more lock file refactoringGravatar Joey Hess2014-08-20
|
* reorganize and refactor lock codeGravatar Joey Hess2014-08-20
| | | | | | | | Added a convenience Utility.LockFile that is not a windows/posix portability shim, but still manages to cut down on the boilerplate around locking. This commit was sponsored by Johan Herland.
* Ensure that all lock fds are close-on-exec, fixing various problems with ↵Gravatar Joey Hess2014-08-20
| | | | | | | | | | | | | | | | | | them being inherited by child processes such as git commands. (With the exception of daemon pid locking.) This fixes at part of #758630. I reproduced the assistant locking eg, a removable drive's annex journal lock file and forking a long-running git-cat-file process that inherited that lock. This did not affect Windows. Considered doing a portable Utility.LockFile layer, but git-annex uses posix locks in several special ways that have no direct Windows equivilant, and it seems like it would mostly be a complication. This commit was sponsored by Protonet.
* add compat cruft for old versions of http-types and http-conduitGravatar Joey Hess2014-08-17
|
* work around default Accept-Encoding in http-clientGravatar Joey Hess2014-08-15
|
* memoize construction of the Request -> Request function to apply the UrlOptionsGravatar Joey Hess2014-08-15
|