Commit graph

17636 commits

Author SHA1 Message Date
Joey Hess
c85a482136 improve view branch name when there are a list of values 2014-02-19 16:35:00 -04:00
Joey Hess
dd7b99c860 add tip about metadata driven views (and more flexible view filtering)
While writing this documentation, I realized that there needed to be a way
to stay in a view like tag=* while adding a filter like tag=work that
applies to the same field.

So, there are really two ways a view can be refined. It can have a new
"field=explicitvalue" filter added to it, which does not change the
"shape" of the view, but narrows the files it shows.
Or, it can have a new view added, which adds another level of
subdirectories.

So, added a vfilter command, which takes explicit values to add to the
filter, and rejects changes that would change the shape of the view.

And, made vadd only accept changes that change the shape of the view.

And, changed the View data type slightly; now components that can match
multiple metadata values can be visible, or not visible.

This commit was sponsored by Stelian Iancu.
2014-02-19 16:29:56 -04:00
Joey Hess
d8ce6cac36 metadata: add --tag and --untag shorthand options 2014-02-19 15:04:12 -04:00
Joey Hess
e7672f197e new section for metadata 2014-02-19 14:55:34 -04:00
Joey Hess
39ebfa1a2e pre-commit: Update metadata when committing changes to annexed files within a view.
So the user can now switch to a view and then move files around within it
to manage metadata. For example, moving a file into a new directory
when in the tags=* view adds a tag to it.

Implementation is fairly efficient. One diff-index, which is no more
expensive than the first stage of a git commit, followed by possibly
some cat-file --batch traffic to find the key (when deleting a file).
Very similar to what's done in direct mode when committing. And like
direct mode when updating the WC after a merge, it has to buffer the
diff-tree values in order to make 2 passes over them.

When not in a view, pre-commit now does one extra git symbolic-ref,
which is tiny overhead.

This commit was sponsored by Andrew Eskridge.
2014-02-19 14:17:58 -04:00
Joey Hess
02259d2a55 speed up currentView when not in a view
Avoid reading the view log when the branch is clearly not a view branch.
2014-02-19 12:52:47 -04:00
Joey Hess
1fe6cd3c0d decruft 2014-02-19 02:32:22 -04:00
Joey Hess
fb266e2da6 make view globs case-insensative, memoized, and bring back TFDA
I was careful to write the code so its clear how laziness memoizes it,
although it's likely that much less explicit currying would have had
the same effect. Verified that the memoization works using a Debug.Trace.
2014-02-19 02:30:14 -04:00
Joey Hess
0b7ede2088 reject views with too many nested subdirs 2014-02-19 01:28:48 -04:00
Joey Hess
4e0be2792b remove Read instance for Ref
Removed instance, got it all to build using fromRef. (With a few things
that really need to show something using a ref for debugging stubbed out.)

Then added back Read instance, and made Logs.View use it for serialization.
This changes the view log format.
2014-02-19 01:19:57 -04:00
Joey Hess
eb7b8747f9 Merge branch 'master' of ssh://git-annex.branchable.com 2014-02-18 22:13:34 -04:00
Joey Hess
587a81e42f
vpop N: remove skipped over views 2014-02-18 22:12:42 -04:00
https://www.google.com/accounts/o8/id?id=AItOawm3ayIrWKe5SqLYomXiCL-l2CDpREvA-IE
3a94295ed1 Added a comment: Seconding this Bug. 2014-02-19 02:04:34 +00:00
Joey Hess
57d7491d1f
devblog 2014-02-18 21:58:19 -04:00
Joey Hess
1a53c87057 vpop N 2014-02-18 21:57:21 -04:00
Joey Hess
8ff05cf55b Merge branch 'view' 2014-02-18 21:50:24 -04:00
Joey Hess
fafb51946c Merge branch 'master' of ssh://git-annex.branchable.com 2014-02-18 21:36:08 -04:00
Joey Hess
2bf338f443 fixed vpop 2014-02-18 21:09:25 -04:00
Joey Hess
72c118152f fix view changing when in subdir
Failed reading some files with relative paths. This is a quick and dirty
fix.
2014-02-18 20:57:14 -04:00
Joey Hess
9b51d43318 view: preserve toplevel dotfiles 2014-02-18 20:32:00 -04:00
Joey Hess
67a5f02a0b add vcycle command 2014-02-18 20:16:28 -04:00
Joey Hess
f603692a72 add vadd command 2014-02-18 20:02:09 -04:00
Joey Hess
5790acc19f improve view filenames 2014-02-18 20:01:44 -04:00
http://23.gs/
0e6173ab57 2014-02-18 23:59:16 +00:00
Greg Grossmeier
4650a1f749 initremote -> enableremote, pretty sure 2014-02-18 15:53:48 -08:00
http://grossmeier.net/
be67112e43 Added a comment: missing steps? 2014-02-18 23:51:01 +00:00
Joey Hess
67fd06af76 add git annex view command
(And a vpop command, which is still a bit buggy.)

Still need to do vadd and vrm, though this also adds their documentation.

Currently not very happy with the view log data serialization. I had to
lose the TDFA regexps temporarily, so I can have Read/Show instances of
View. I expect the view log format will change in some incompatable way
later, probably adding last known refs for the parent branch to View
or something like that.

Anyway, it basically works, although it's a bit slow looking up the
metadata. The actual git branch construction is about as fast as it can be
using the current git plumbing.

This commit was sponsored by Peter Hogg.
2014-02-18 18:22:20 -04:00
https://www.google.com/accounts/o8/id?id=AItOawk9nck8WX8-ADF3Fdh5vFo4Qrw1I_bJcR8
32ecaad586 2014-02-18 18:28:27 +00:00
http://geoffreyirving.myopenid.com/
a345c74e8a Added a comment: encrypted home directory 2014-02-18 18:05:25 +00:00
http://geoffreyirving.myopenid.com/
1585480c37 2014-02-18 17:49:35 +00:00
stp
5c81fce77f 2014-02-17 23:27:05 +00:00
stp
759ccd0601 Added a comment: Update one forgetting keys no longer present 2014-02-17 23:21:49 +00:00
https://www.google.com/accounts/o8/id?id=AItOawnFjuvfPpi1kf6l54bxfFUm0Aw_Gf_IO0o
8f10390095 Added a comment: Too big to fsck 2014-02-17 22:33:39 +00:00
Joey Hess
e640d768ed Merge branch 'master' of ssh://git-annex.branchable.com 2014-02-17 12:24:50 -04:00
stp
b820820ba3 Added a comment: Earlier version syntax was removed 2014-02-17 16:05:34 +00:00
stp
30561e2f02 removed 2014-02-17 16:05:10 +00:00
stp
cda6566514 Added a comment: Earlier version syntax was removed 2014-02-17 16:01:16 +00:00
stp
035b6c8552 2014-02-17 15:56:56 +00:00
stp
9e8370d1b9 Fix command to match fsck description 2014-02-17 15:53:46 +00:00
stp
d873483be6 2014-02-17 15:49:10 +00:00
stp
ee37c0b79a 2014-02-17 15:38:36 +00:00
https://renaud.casenave.fr/
8f1e02f2a8 Added a comment 2014-02-17 13:15:24 +00:00
Helmut Grohne
008b4ca27e comment on descriptive git-annex commit messages 2014-02-17 08:45:43 +01:00
Joey Hess
103dab702b better data types 2014-02-17 00:38:33 -04:00
https://www.google.com/accounts/o8/id?id=AItOawn3rK4VDzxyhmrIc18z7F5OuXvEbUsgUac
a7441a3d69 Added a comment: no more issue 2014-02-17 04:25:42 +00:00
Joey Hess
e806152f77 split out types 2014-02-17 00:18:57 -04:00
https://www.google.com/accounts/o8/id?id=AItOawn3rK4VDzxyhmrIc18z7F5OuXvEbUsgUac
fb56b4ecfb Added a comment: Progress, but still issues 2014-02-17 04:09:23 +00:00
Joey Hess
d7a95098fb
tricky view refining code that keeps track of whether the view is widenening or narrowing 2014-02-16 22:44:28 -04:00
Joey Hess
410f603383 support globs when built w/o TDFA, just slower 2014-02-16 21:26:57 -04:00
Joey Hess
613f8f02e3
add another quickcheck property, and several edge cases handled 2014-02-16 21:00:12 -04:00