nd/list-files updates
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest21 patches 8 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/21 | ls_colors.c: add $LS_COLORS parsing codeMakefile color.h ls_colors.c | +407 | 0 replies | |
| 2/21 | ls_colors.c: parse color.ls.* from config fileDocumentation/ ls_colors.c | +37 | 0 replies | |
| 3/21 | ls_colors.c: add a function to color a file namecolor.h ls_colors.c | +68 | 0 replies | |
| 4/21 | ls_colors.c: highlight submodules like directoriesDocumentation/ ls_colors.c | +9 | 0 replies | |
| 5/21 | ls-files: buffer full item in strbuf before printingbuiltin/ | +35 | 0 replies | |
| 6/21 | ls-files: add --color to highlight file namesDocumentation/ builtin/ | +42 | 0 replies | |
| 7/21 | ls-files: add --columnDocumentation/ builtin/ | +34 | 0 replies | |
| 8/21 | ls-files: support --max-depthDocumentation/ builtin/ | +14 | 0 replies | |
| 9/21 | list-files: a user friendly version of ls-files and more.gitignore Documentation/ Documentation/ +4 more | +159 | 1 reply | |
| 10/21 | list-files: make alias 'ls' default to 'list-files'Documentation/ config.c | +10 | 0 replies | |
| 11/21 | list-files: -u does not imply showing stagesbuiltin/ | +1 | 0 replies | |
| 12/21 | list-files: add -R/--recursive short for --max-depth=-1Documentation/ builtin/ | +6 | 0 replies | |
| 13/21 | list-files: add -1 short for --no-columnDocumentation/ builtin/ | +5 | 0 replies | |
| 14/21 | list-files: add -t backDocumentation/ builtin/ | +23 | 0 replies | |
| 15/21 | list-files: sort output and remove duplicatesbuiltin/ | +24 | 0 replies | |
| 16/21 | list-files: do not show duplicate cached entriesbuiltin/ | +51 | 0 replies | |
| 17/21 | list-files: show directories as well as filesbuiltin/ | +50 | 2 replies | |
| 18/21 | list-files: add -F/--classifyDocumentation/ builtin/ | +37 | 0 replies | |
| 19/21 | list-files -F: show submodules with the new indicator '&'Documentation/ builtin/ | +4 | 0 replies | |
| 20/21 | list-files: -M aka diff-cachedbuiltin/ | +64 | 0 replies | |
| 21/21 | t3080: tests for git-list-filest/ t/ t/ | +127 | 5 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH 00/21] nd/list-files updates
Changes since 'pu' version:
- refresh_index() in 09/21 is set not to show "XXX: needs merge" messages, cluttering "list-files -u" output
- new patch 10/21 to add a default alias 'ls' to 'list-files', of course overridable by the user
- fix "list-files -u" not showing anything because show_files_compact in 16/21 ignores show_unmerged flag
- directory listing in 17/21 is rewritten to work filtering (e.g. -m, -M...)
- new patch 21/21 adds tests for the series
Nguyễn Thái Ngọc Duy (21):
ls_colors.c: add $LS_COLORS parsing code ls_colors.c: parse color.ls.* from config file ls_colors.c: add a function to color a file name ls_colors.c: highlight submodules like directories
ls-files: buffer full item in strbuf before printing
ls-files: add --color to highlight file names
ls-files: add --column
ls-files: support --max-depth
list-files: a user friendly version of ls-files and more
list-files: make alias 'ls' default to 'list-files'
list-files: -u does not imply showing stages
list-files: add -R/--recursive short for --max-depth=-1
list-files: add -1 short for --no-column
list-files: add -t back
list-files: sort output and remove duplicates
list-files: do not show duplicate cached entries
list-files: show directories as well as files
list-files: add -F/--classify
list-files -F: show submodules with the new indicator '&'
list-files: -M aka diff-cached
t3080: tests for git-list-files
Total diff against 'pu' is something like this
-- 8< --
Documentation/git-list-files.txt +2 -1
@@ -14,7 +14,8 @@ DESCRIPTION ----------- List files (by default in current working directory) that are in the index. Depending on the chosen options, maybe only modified files in -working tree are shown, or untracked files... +working tree are shown, or untracked files... The builtin alias "ls" +is set to "list-files". OPTIONS -------
builtin/ls-files.c +62 -46
176 lines not on this page · raw message
config.c +8 -0
@@ -40,6 +40,10 @@ static struct config_source *cf;static int zlib_compression_seen; +static const char *builtin_config = +"[alias]\n" +" ls = list-files\n" ; +/* * Default config_set that contains key-value pairs from the usual set of config * config files (i.e repo specific .git/config, user wide ~/.gitconfig, XDG
@@ -1175,6 +1179,10 @@ int git_config_early(config_fn_t fn, void *data, const char *repo_config)home_config_paths (&user_config, &xdg_config,"config" ); +if (git_config_system ()) +git_config_from_buf (fn,"<builtin>" , builtin_config, +strlen (builtin_config), data); +if (git_config_system () && !access_or_die (git_etc_gitconfig (),R_OK ,0 )) { ret +=git_config_from_file (fn,git_etc_gitconfig (), data);
t/t3080-list-files.sh new file +122 -0
122 lines not on this page · raw message
t/t3080/color_ls new file +3 -0
@@ -0,0 +1,3 @@ +[32mdir[m +[31mfile[m +[33mgitlink[m
t/t3080/ls_colors new file +2 -0
@@ -0,0 +1,2 @@ +[32mdir[m +[31mfile[m
-- 8< --
Signature · 1 line
2.2.0.84.ge9c7a8a