summaryrefslogtreecommitdiff
path: root/Annex/View.hs
Commit message (Collapse)AuthorAge
* fix combining of FIlterValuesGravatar Joey Hess2014-03-02
|
* vadd: Allow listing multiple desired values for a field.Gravatar Joey Hess2014-03-02
|
* view, vfilter: Add support for filtering tags and values out of a view, ↵Gravatar Joey Hess2014-03-02
| | | | | | | | | | using !tag and field!=value. Note that negated globs are not supported. Would have complicated the code to add them, without changing the data type serialization in a non-backwards-compatable way. This commit was sponsored by Denver Gingerich.
* metadata: FIeld names are now case insensative.Gravatar Joey Hess2014-02-25
|
* annex.genmetadata can be set to make git-annex automatically set metadata ↵Gravatar Joey Hess2014-02-23
| | | | (year and month) when adding files
* exclude derived metadata when extracting metadata from a viewed fileGravatar Joey Hess2014-02-22
|
* views: add automatically constructed file location metadataGravatar Joey Hess2014-02-22
| | | | | | | | | | | | | | | | | | | | | | | When constructing views, metadata is available about the location of the file in the view's reference branch. Allows incorporating parts of the directory hierarchy in a view. For example `git annex view tag=* podcasts/=*` makes a view in the form tag/showname. Performance impact: I benchmarked git annex view tag=* in the conference proceedings repo to take 6.459s before this change, and 6.544s after. FWIW, I considered making the syntax for this be podcasts/*, which might be easier for the user to learn. However, I think it's not as good: * The user has to then juggle two different syntaxes, and podcasts/* will be expanded by the shell so they also need to quote it, while podcasts/=* is unlikely to be expanded by the shell. * It would allow for things like podcasts/*/* and *.mp3 which do not map well into views. This commit was sponsored by Aurélien Pinceaux.
* factor out new moduleGravatar Joey Hess2014-02-22
|
* --metadata field=value can now use globs to match, and matches case ↵Gravatar Joey Hess2014-02-21
| | | | | | insensatively, the same as git annex view field=value does. Also refactored glob code into its own module.
* add tip about metadata driven views (and more flexible view filtering)Gravatar Joey Hess2014-02-19
| | | | | | | | | | | | | | | | | | | | | | 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.
* pre-commit: Update metadata when committing changes to annexed files within ↵Gravatar Joey Hess2014-02-19
| | | | | | | | | | | | | | | | | | | | 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.
* decruftGravatar Joey Hess2014-02-19
|
* make view globs case-insensative, memoized, and bring back TFDAGravatar Joey Hess2014-02-19
| | | | | | 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.
* reject views with too many nested subdirsGravatar Joey Hess2014-02-19
|
* remove Read instance for RefGravatar Joey Hess2014-02-19
| | | | | | | | 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.
* fix view changing when in subdirGravatar Joey Hess2014-02-18
| | | | | Failed reading some files with relative paths. This is a quick and dirty fix.
* view: preserve toplevel dotfilesGravatar Joey Hess2014-02-18
|
* improve view filenamesGravatar Joey Hess2014-02-18
|
* add git annex view commandGravatar Joey Hess2014-02-18
| | | | | | | | | | | | | | | | | | (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.
* better data typesGravatar Joey Hess2014-02-17
|
* split out typesGravatar Joey Hess2014-02-17
|
* tricky view refining code that keeps track of whether the view is widenening ↵Gravatar Joey Hess2014-02-16
| | | | or narrowing
* support globs when built w/o TDFA, just slowerGravatar Joey Hess2014-02-16
|
* add another quickcheck property, and several edge cases handledGravatar Joey Hess2014-02-16
|
* simplify typeGravatar Joey Hess2014-02-16
|
* filter branches (incomplete)Gravatar Joey Hess2014-02-16
Promosing work toward metadata driven filter branches. A few methods to construct them are stubbed out; all the data types and pure code seems good. This commit was sponsored by Walter Somerville.