-
-
Notifications
You must be signed in to change notification settings - Fork 658
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement file name colouring in {exa,ls}_colors
This commit adds to the parsing of the LS_COLORS and EXA_COLORS variables so that non-two-letter codes (keys other than things like ‘di’ or ‘ln’ or ‘ex’) will be treated as file name globs, and get used to colour files accordingly. Fixes #116 for good.
- Loading branch information
Showing
9 changed files
with
348 additions
and
57 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
[36m/testcases/file-names-exts/[1;37mcompressed.deb[0m | ||
[36m/testcases/file-names-exts/[1;37mcompressed.tar.gz[0m | ||
[36m/testcases/file-names-exts/[1;37mcompressed.tar.xz[0m | ||
[36m/testcases/file-names-exts/[31mcompressed.tgz[0m | ||
[36m/testcases/file-names-exts/[31mcompressed.txz[0m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
[36m/testcases/file-names-exts/[1;37mcompressed.deb[0m | ||
[36m/testcases/file-names-exts/[1;37mcompressed.tar.gz[0m | ||
[36m/testcases/file-names-exts/[1;37mcompressed.tar.xz[0m | ||
[36m/testcases/file-names-exts/[0mcompressed.tgz | ||
[36m/testcases/file-names-exts/[0mcompressed.txz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[34manother: [[1m\n[0m[34m][0m [32m->[0m [4;36m/testcases/file-names/new-line-dir: [[0m[1;34m\n[0m[4;36m]/[0manother: [[1;34m\n[0m] | ||
[34mbroken[0m [32m->[0m [1;4;32m/testcases/file-names/new-line-dir: [[34m\n[32m]/broken[0m | ||
[34msubfile[0m [32m->[0m [4;36m/testcases/file-names/new-line-dir: [[0m[1;34m\n[0m[4;36m]/[0msubfile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
[38;5;250m.[38;5;237m---------[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m000[0m | ||
[38;5;250m.[38;5;237m--------[38;5;121mx[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m001[0m | ||
[38;5;250m.[38;5;237m-------[38;5;120mw[38;5;237m-[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m002[0m | ||
[38;5;250m.[38;5;237m------[38;5;119mr[38;5;237m--[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m004[0m | ||
[38;5;250m.[38;5;237m-----[38;5;118mx[38;5;237m---[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m010[0m | ||
[38;5;250m.[38;5;237m----[38;5;190mw[38;5;237m----[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m020[0m | ||
[38;5;250m.[38;5;237m---[38;5;191mr[38;5;237m-----[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m040[0m | ||
[38;5;250m.[38;5;237m--[38;5;192mx[38;5;237m------[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;48m100[0m | ||
[38;5;250m.[38;5;237m-[38;5;193mw[38;5;237m-------[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m200[0m | ||
[38;5;250m.[38;5;194mr[38;5;237m--------[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m400[0m | ||
[38;5;250m.[38;5;194mr[38;5;193mw[38;5;237m-[38;5;191mr[38;5;237m--[38;5;119mr[38;5;237m--[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m644[0m | ||
[38;5;250m.[38;5;194mr[38;5;193mw[38;5;192mx[38;5;191mr[38;5;237m-[38;5;118mx[38;5;119mr[38;5;237m-[38;5;121mx[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;48m755[0m | ||
[38;5;250m.[38;5;194mr[38;5;193mw[38;5;192mx[38;5;191mr[38;5;190mw[38;5;118mx[38;5;119mr[38;5;120mw[38;5;121mx[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;48m777[0m | ||
[38;5;250m.[38;5;237m--------[38;5;50mT[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m1000[0m | ||
[38;5;250m.[38;5;237m--------[38;5;50mt[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m1001[0m | ||
[38;5;250m.[38;5;237m-----[38;5;50mS[38;5;237m---[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m2000[0m | ||
[38;5;250m.[38;5;237m-----[38;5;50ms[38;5;237m---[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m2010[0m | ||
[38;5;250m.[38;5;237m--[38;5;50mS[38;5;237m------[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m4000[0m | ||
[38;5;250m.[38;5;237m--[38;5;51ms[38;5;237m------[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;48m4100[0m | ||
[38;5;250m.[38;5;194mr[38;5;193mw[38;5;50mS[38;5;191mr[38;5;190mw[38;5;50mS[38;5;119mr[38;5;120mw[38;5;50mT[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;250m7666[0m | ||
[38;5;250m.[38;5;194mr[38;5;193mw[38;5;51ms[38;5;191mr[38;5;190mw[38;5;50ms[38;5;119mr[38;5;120mw[38;5;50mt[0m [38;5;49m0[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;48m7777[0m | ||
[38;5;195md[38;5;237m---------[0m [38;5;237m-[0m [38;5;46mcassowary[0m [38;5;47m 1 Jan 12:34[0m [38;5;195mforbidden-directory[0m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[31mblock-device[0m | ||
[32mchar-device[0m | ||
[34mnamed-pipe[0m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#SAVEFILE# | ||
backup~ | ||
compiled.class | ||
compiled.coffee | ||
compiled.js | ||
compiled.o | ||
compressed.deb | ||
compressed.tar.gz | ||
compressed.tar.xz | ||
compressed.tgz | ||
compressed.txz | ||
COMPRESSED.ZIP | ||
crypto.asc | ||
crypto.signature | ||
document.pdf | ||
DOCUMENT.XLSX | ||
file.tmp | ||
IMAGE.PNG | ||
image.svg | ||
lossless.flac | ||
lossless.wav | ||
Makefile | ||
music.mp3 | ||
MUSIC.OGG | ||
VIDEO.AVI | ||
video.wmv |