GSOC: Unify the commands `git tag -l`, `git brach -l` and `git for-each-ref`
- From
Karthik Nayak <karthik.188@gmail.com>
- Date
- Aug 22, 2015, 07:45 UTC
- Message-ID
- <CAOLa=ZRS-f0tOo+EC0_Su8aZ8cz9pratmg4vjkG+DC8gAeYAJw@mail.gmail.com>
Hello All,
As part of GSoC I'm working on the Unification of 'for-each-ref', 'tag -l' and 'branch -l'.
Current Progress:
1. Building ref-filter.{c,h} from for-each-ref.
This is the process of creating an initial library for the unification
by moving most of the code from for-each-ref to ref-filter.{c,h}.
Merged into next2. Add options to ref-filter. This includes the porting of --points-at, --contains, --merged, --no-merged options from builtin/branch.c and builtin/tag.c, Also the implementation of these options into for-each-ref. Merged to next
3. Port builtin/tag.c to use ref-filter. Here we port tag.c to use ref-filter and also port the --format, --sort and --merged and --no-merged options to builtin/tag.c. Version 13 can be found here: * http://thread.gmane.org/gmane.comp.version-control.git/276363 There was a lot of discussion on v12 (especially how %(align)...%(end) should be handling '--quote') which can be found here: * http://thread.gmane.org/gmane.comp.version-control.git/276133
4. Port builtin/branch.c to use ref-filter filtering APIs. Here we make use of the filtering APIs provided by ref-filter to filter out branches. Also make it learn the '--points-at' command. version 3 can be found here: * http://thread.gmane.org/gmane.comp.version-control.git/276377
As my mentors suggested, I'm working on the printing aspects of branch.c now. This involves supporting %(if)....%(then)....%(else)....%(end). and making branch.c use show_ref_array_item() rather than using its own implementation.
As the ground has been laid for %(align)....%(end) atom, the work shouldn't be of much difficulty.
Will push most of my work to github: github.com/KarthikNayak/git
-- Regards, Karthik Nayak