Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 672638fa2d
Fetching contributors…

Cannot retrieve contributors at this time

213 lines (165 sloc) 4.066 kb
# 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
magnus@trapd00r.se
http://japh.se
=head1 REPORTING BUGS
Report bugs and/or feature requests on L<https://github.com/trapd00r/ls--/issues>
or to L<magnus@trapd00r.se>
=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:
Jump to Line
Something went wrong with that request. Please try again.