App-lsplusplus

 view release on metacpan or  search on metacpan

ls++.conf  view on Meta::CPAN

# vim:ft=perl:fdm=marker:fmr=#<,#>:fen:et:sw=2:
# ls++ configuration file
# location: $XDG_CONFIG_HOME/ls++/ls++.conf

use utf8;
#< do not modify this ok?
use vars qw(
  @ignores
  @d
  @c
  $colorscheme
  %ls_colors
  $symlink_delim
  $symlink_color
  $symlink_attr
);
@c = (0 .. 16);
#>

# Colorscheme to use. You can define your own further down this file.
$colorscheme = 'trapd00r';

# delimiters used in the file listing
@d = qw(▕ - │ ▏);

#$d[0] = '├';
#$d[1] = ' ';
#$d[2] = '▕▏';
#$d[3] = '┤';

# How should symlinks be displayed?
$symlink_delim = '=>';
$symlink_color = 1;
$symlink_attr  = 'bold';


# Here you can define your own custom LS_COLORS rules, much more
# powerful than the regular LS_COLORS that'll only match on an
# extension.
#
# To color (all) directories differently, match a trailing slash
# like so:
#
#   '/$' => 'bold blue8 underline'
#
# Available attributes are:
#  - 0-255  color index
#  - any valid X color name
#  - bold, underline, italic...
#
# And you can nest them too:
#
#   'README.(md|pod)$' => 'bold italic 197 underline',
#
# Remember, these rules are powerful! Match a season premiere and have
# it stand out:
#
# '(?i)(s[0-9]{2}-s[0-9]{2}|s([0-9]{1,2})[eEx]01)|([Ss]?([0-9]{1,2}))[Eex]01' => 'underline bold 196',


%ls_colors = (
  '\.un~$'         => 'IGNORE',
  '\.sw[o-z]$'     => 'IGNORE',
  'README$'        => 'bold 220 underline',
  'Makefile$'      => $c[15],
  '(=:.+)?\..*rc'  => $c[3],
#  '/$'             => 'blue8',
);

#< colorschemes
# 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;

ls++.conf  view on Meta::CPAN

/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
  m@japh.se
  http://japh.se

=head1 REPORTING BUGS

Report bugs and/or feature requests on L<https://github.com/trapd00r/ls--/issues>
or to L<m@japh.se>

=head1 COPYRIGHT

Copyright (C) 2010, 2011, 2018- 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;



( run in 1.338 second using v1.01-cache-2.11-cpan-39bf76dae61 )