Commit graph

3687 commits

Author SHA1 Message Date
Joey Hess
bb4f31a0ee Clean up handling of git directory and git worktree.
Baked into the code was an assumption that a repository's git directory
could be determined by adding ".git" to its work tree (or nothing for bare
repos). That fails when core.worktree, or GIT_DIR and GIT_WORK_TREE are
used to separate the two.

This was attacked at the type level, by storing the gitdir and worktree
separately, so Nothing for the worktree means a bare repo.

A complication arose because we don't learn where a repository is bare
until its configuration is read. So another Location type handles
repositories that have not had their config read yet. I am not entirely
happy with this being a Location type, rather than representing them
entirely separate from the Git type. The new code is not worse than the
old, but better types could enforce more safety.

Added support for core.worktree. Overriding it with -c isn't supported
because it's not really clear what to do if a git repo's config is read, is
not bare, and is then overridden to bare. What is the right git directory
in this case? I will worry about this if/when someone has a use case for
overriding core.worktree with -c. (See Git.Config.updateLocation)

Also removed and renamed some functions like gitDir and workTree that
misused git's terminology.

One minor regression is known: git annex add in a bare repository does not
print a nice error message, but runs git ls-files in a way that fails
earlier with a less nice error message. This is because before --work-tree
was always passed to git commands, even in a bare repo, while now it's not.
2012-05-18 17:03:12 -04:00
Joey Hess
a2be4265bf add 2012-05-16 15:19:39 -04:00
Joey Hess
f4b96ee44e Merge branch 'master' of ssh://git-annex.branchable.com 2012-05-15 14:20:48 -04:00
Joey Hess
e36808e167 Pass -a to cp even when it supports --reflink=auto, to preserve permissions.
Amoung other things, this makes unlocking a WORM backed file and then
re-adding it without making any changes not add a new object, as the
timestamp is preserved.
2012-05-15 14:18:51 -04:00
http://joeyh.name/
a25237d205 Added a comment 2012-05-15 17:00:10 +00:00
https://www.google.com/accounts/o8/id?id=AItOawnpdM9F8VbtQ_H5PaPMpGSxPe_d5L1eJ6w
300d3cbdef Added a comment 2012-05-15 07:59:58 +00:00
https://www.google.com/accounts/o8/id?id=AItOawnpdM9F8VbtQ_H5PaPMpGSxPe_d5L1eJ6w
1e590dcc47 Added a comment 2012-05-15 07:36:25 +00:00
https://www.google.com/accounts/o8/id?id=AItOawlYu7QmD7wrbHWkoxuriaA9XcijM-g5vrQ
461367f23b 2012-05-15 02:42:31 +00:00
https://www.google.com/accounts/o8/id?id=AItOawkRITTYYsN0TFKN7G5sZ6BWGZOTQ88Pz4s
b261d09637 Added a comment: cygwin 2012-05-15 00:14:10 +00:00
Joey Hess
2701800cda cleanup 2012-05-11 12:38:56 -04:00
Joey Hess
1c942c898d add news item for git-annex 3.20120511 2012-05-11 12:38:08 -04:00
Joey Hess
61a5df33d4 releasing version 3.20120511 2012-05-11 12:37:26 -04:00
https://www.google.com/accounts/o8/id?id=AItOawlYu7QmD7wrbHWkoxuriaA9XcijM-g5vrQ
f02db7bfce Added a comment 2012-05-10 19:21:08 +00:00
http://joeyh.name/
891684f85d Added a comment 2012-05-10 19:17:22 +00:00
https://www.google.com/accounts/o8/id?id=AItOawlYu7QmD7wrbHWkoxuriaA9XcijM-g5vrQ
8734e7cba5 Added a comment: Git annex content transfer protocols 2012-05-10 19:13:48 +00:00
http://joeyh.name/
daaeba3afb Added a comment 2012-05-10 18:51:56 +00:00
https://www.google.com/accounts/o8/id?id=AItOawlYu7QmD7wrbHWkoxuriaA9XcijM-g5vrQ
660f5de551 Added a comment: Protocols to transfer file content 2012-05-10 18:48:41 +00:00
Joey Hess
7943318ec6 Merge branch 'master' of ssh://git-annex.branchable.com 2012-05-10 14:26:55 -04:00
Joey Hess
32a41f8af1 add a favicon 2012-05-10 14:18:35 -04:00
http://joeyh.name/
ab84b612ea Added a comment: rsync over ssh 2012-05-10 18:18:01 +00:00
https://www.google.com/accounts/o8/id?id=AItOawlYu7QmD7wrbHWkoxuriaA9XcijM-g5vrQ
ef247f3da7 2012-05-10 13:14:50 +00:00
http://joeyh.name/
ac08c37649 Added a comment 2012-05-08 18:22:12 +00:00
https://me.yahoo.com/a/IAg3idYGk.joxsJb2WCxl20gig.0.8hS#d5165
3770bc5d41 2012-05-07 21:57:58 +00:00
Joey Hess
bbfa74e7ac format 2012-05-07 13:19:00 -04:00
Joey Hess
f7d8982672 Fix use of several config settings
annex.ssh-options, annex.rsync-options, annex.bup-split-options.

And adjust types to avoid the bugs that broke several config settings
recently. Now "annex." prefixing is enforced at the type level.
2012-05-05 20:16:56 -04:00
Joey Hess
657d09d499 fix build 2012-05-05 20:11:08 -04:00
Joey Hess
8c09c17f6b use strict insertWith 2012-05-04 00:44:11 -04:00
Joey Hess
32de288c35 syntax tweaks
Although I hate to lose one of the only places I've ever used the list monad..
2012-05-02 19:51:41 -04:00
Joey Hess
441b138592 followup and close 2012-05-02 15:03:44 -04:00
Joey Hess
392931eca9 addunused: New command, the opposite of dropunused, it relinks unused content into the git repository. 2012-05-02 14:59:05 -04:00
Joey Hess
7d6b36dffb deseq 2012-05-02 13:22:04 -04:00
Joey Hess
d8606a327d portage overlay 2012-05-02 13:20:21 -04:00
Joey Hess
ea0c48bfcd gentoo 2012-05-02 13:18:21 -04:00
Joey Hess
c058cdf461 move 2012-05-02 13:17:51 -04:00
Joey Hess
8f45300479 dropunused: Allow specifying ranges to drop.
Sort of by popular demand, but the last straw for not using seq
was that it can run into command line length limits.
2012-05-02 13:15:19 -04:00
Joey Hess
6d61067599 rsync shellescape disable option
Rsync special remotes can be configured with shellescape=no to avoid shell
quoting that is normally done when using rsync over ssh. This is known to
be needed for certian rsync hosting providers (specificially
hidrive.strato.com) that use rsync over ssh but do not pass it through the
shell.
2012-05-02 13:08:33 -04:00
Joey Hess
17fd57bd81 hidrive.strato.com 2012-05-02 11:50:57 -04:00
Joey Hess
913775410b update 2012-05-02 11:43:30 -04:00
Joey Hess
5337c4e0c4 rsync protocol? 2012-05-02 11:38:27 -04:00
http://id.wgnr.me/
834e73cde5 2012-05-02 14:09:28 +00:00
Joey Hess
8f8f7ecf6f recycled comment 2012-05-01 20:34:28 -04:00
https://www.google.com/accounts/o8/id?id=AItOawkaT0B6s9jQuMzQUYRVBgWqtO7BhT_ZSaE
153912633e 2012-05-02 00:27:52 +00:00
Joey Hess
1f5965fa0d add news item for git-annex 3.20120430 2012-04-30 14:34:08 -04:00
Joey Hess
f377cbc129 update 2012-04-30 14:23:18 -04:00
Joey Hess
76b80d6af0 releasing version 3.20120430 2012-04-30 13:59:28 -04:00
Joey Hess
bf70bbdbfc fix test suite build 2012-04-30 13:59:05 -04:00
Joey Hess
0c9c14b52f percentage library 2012-04-29 17:48:07 -04:00
Joey Hess
d2bfba6324 show percent the bloom filter is full 2012-04-29 16:10:47 -04:00
Joey Hess
bd592d1450 refactor 2012-04-29 14:33:07 -04:00
http://joey.kitenet.net/
9f04367336 Added a comment 2012-04-29 18:04:13 +00:00