Changeset 2386


Ignore:
Timestamp:
Sep 7, 2016, 2:09:02 PM (3 years ago)
Author:
kbut
Message:

add blacklist to keep-skel

Location:
keep-skel/trunk/fuentes
Files:
3 added
2 edited

Legend:

Unmodified
Added
Removed
  • keep-skel/trunk/fuentes/debian/changelog

    r184 r2386  
     1keep-skel (0.28) xenial; urgency=medium
     2
     3  * Add blacklist to keep-skel
     4
     5 -- Raul Rodrigo Segura <raurodse@gmail.com>  Wed, 07 Sep 2016 14:07:42 +0200
     6
    17keep-skel (0.27) xenial; urgency=high
    28
  • keep-skel/trunk/fuentes/keep-skel.install/usr/bin/keep-skel

    r183 r2386  
    1616my $force;
    1717my $num_args;
    18 
     18my @rules;
     19my $rulespath = '/usr/share/keep-skel/rules';
     20sub get_rules(){
     21        if ( -e $rulespath ){
     22                open(my $fd ,$rulespath );
     23                while(my $row = <$fd>){
     24                        chomp $row;
     25                        push(@rules,$row);
     26                }
     27        }
     28}
    1929
    2030sub show_usage()
     
    3040
    3141        # Destination file
     42        my $needle = $File::Find::name;
     43        $needle =~ s/\/etc\/skel\///g;
     44        foreach(@rules){
     45                if ($needle =~ /$_/ ){
     46                        return;
     47                }
     48        }
    3249        my $destinationFile="";
    3350        $destinationFile=$File::Find::name;
    3451        $destinationFile =~ s/\/etc\/skel/\/home\/$user/g;
    35        
     52        print $destinationFile."\n";
     53        return ;
    3654        # If it is a directory....
    3755        if ( -d $File::Find::name )
     
    8199                      "verbose"=>\$verbose
    82100                        );
    83 
     101get_rules();
    84102foreach (@users)
    85103{
Note: See TracChangeset for help on using the changeset viewer.