-
Notifications
You must be signed in to change notification settings - Fork 3
/
ls++.conf
212 lines (165 loc) · 3.97 KB
/
ls++.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
# ls++ configuration file
# location: $XDG_CONFIG_HOME/ls++/ls++.conf
use vars qw(@ignores
@d
@c
$colorscheme
%ls_colors
$symlink_delim
$symlink_color
);
$colorscheme = 'trapd00r';
@ignores = (
'\.un~$',
'\.sw[o-z]$',
);
@d = qw(▕ - │ ▏);
#$d[0] = '├';
#$d[1] = ' ';
#$d[2] = '▕▏';
#$d[3] = '┤';
$symlink_delim = '=>';
$symlink_color = 1;
@c = (0 .. 16);
#);
# extended colors
if($colorscheme eq '') {
$c[0] = 208;
$c[1] = 197;
$c[2] = 190;
$c[3] = 196;
$c[4] = 242;
$c[5] = 209;
$c[6] = 185;
$c[7] = 215;
$c[8] = 032;
$c[9] = 061;
$c[10] = 142;
$c[11] = 197;
$c[12] = 106;
$c[13] = 060;
$c[14] = 236;
$c[15] = 215;
}
elsif($colorscheme eq 'greyscale') {
$c[0] = 252;
$c[1] = 251;
$c[2] = 250;
$c[3] = 249;
$c[4] = 239;
$c[5] = 244;
$c[6] = 240;
$c[7] = 242;
$c[8] = 244;
$c[9] = 244;
$c[10] = 243;
$c[11] = 241;
$c[12] = 240;
$c[13] = 239;
$c[14] = 236;
$c[15] = 242;
}
elsif($colorscheme eq 'early') {
$c[0] = 233;
$c[1] = 245;
$c[2] = 250;
$c[3] = 201;
$c[4] = 239;
$c[5] = 209;
$c[6] = 185;
$c[7] = 216;
$c[8] = 244;
$c[9] = 254;
$c[10] = 243;
$c[11] = 241;
$c[12] = 240;
$c[13] = 239;
$c[14] = 237;
$c[15] = 220;
}
elsif($colorscheme eq 'trapd00r') {
$c[0] = 237;
$c[1] = 131;
$c[2] = 107; # K
$c[3] = 075; # G, sec
$c[4] = 240; # day
$c[5] = 209; # +x
$c[6] = 185; # +r
$c[7] = 216; # +w, M
$c[8] = 220;
$c[9] = 208; # hour
$c[10] = 243;
$c[11] = 161;
$c[12] = 240;
$c[13] = 025;
$c[14] = 248; # Bytes, month
$c[15] = 196; # Min
}
%ls_colors = (
'README$' => $c[8],
'Makefile$' => $c[15],
'(=:.+)?\..*rc' => $c[3],
);
=pod
=head1 NAME
ls++.conf - ls++ configuration file
=head1 DESCRIPTION
ls++.conf is the configuration file for ls++(1). ls++ first searches for it at
~/.config/ls++/ls++.conf then at ~/.ls++.conf then at ./ls++.conf and finally at
/etc/ls++.conf.
Lines beginning with a '#' character are comments. All other non-empty lines
are live Perl code. This gives a lot of power to the end user, but it also
allows for fuckups.
Please don't fuckup.
=head1 ENVIRONMENT
=over 8
=item @d
Array containting the characters to use for delimiting the columns.
=item @c
Array containing the colors to be used.
=item $colorscheme
Colorscheme to be used.
=item %ls_colors
A hash where its keys are patterns (possibly valid regular expressions) to be
matched against the files. The values should be attributes or colors which will
be added to the output.
This does the same thing as LS_COLORS, except that you can match against the
full filname, and not only the extension. Using LS_COLORS, you could never match
README or Makefile for example. Those two are matched by default.
The special value IGNORE will ignore all files matching the key pattern.
=back
=head1 COLORS
The default colortable left here for reference (ANSI colors).
0 NULL black
1 NULL bright black
2 K red
3 G, sec bright red
4 day green
5 +x bright green
6 +r yellow
7 +w, M bright yellow
8 other blue
9 hour bright blue
10 magenta
11 +s bright magenta
12 cyan
13 link bright cyan
14 B, month, delim white
15
16 reset
17 bold
=head1 AUTHOR
Magnus Woldrich
CPAN ID: WOLDRICH
http://japh.se
=head1 REPORTING BUGS
Report bugs and/or feature requests on L<https://github.com/trapd00r/ls--/issues>
or to L<[email protected]>
=head1 COPYRIGHT
Copyright (C) 2010 Magnus Woldrich. All right reserved.
This program is free software; you can redistribute it and/or modify it under
the same terms as Perl itself.
=cut
1;
# vim: set ft=perl ts=2 expandtab: