[Bio] / Sprout / SetPermissions.pl Repository:
ViewVC logotype

Diff of /Sprout/SetPermissions.pl

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.4, Tue Oct 3 02:48:59 2006 UTC revision 1.5, Thu Oct 5 21:56:10 2006 UTC
# Line 2  Line 2 
2    
3  =head1 Fix Permissions  =head1 Fix Permissions
4    
5  Fix the permissions for the current NMPDR complex.  Fix the permissions for the current NMPDR complex. Because this method is
6    used during makes, it does not do tracing.
7    
8  The currently-supported command-line options are as follows.  The permissions will be set to group access for the group C<fig>.
   
 =over 4  
   
 =item user  
   
 Name suffix to be used for log files. If omitted, the PID is used.  
   
 =item trace  
   
 Numeric trace level. A higher trace level causes more messages to appear. The  
 default trace level is 2. Tracing will be directly to the standard output  
 as well as to a C<trace>I<User>C<.log> file in the FIG temporary directory,  
 where I<User> is the value of the B<user> option above.  
   
 =item sql  
   
 If specified, turns on tracing of SQL activity.  
   
 =item background  
   
 Save the standard and error output to files. The files will be created  
 in the FIG temporary directory and will be named C<err>I<User>C<.log> and  
 C<out>I<User>C<.log>, respectively, where I<User> is the value of the  
 B<user> option above.  
   
 =item group  
   
 Name of the group to be assigned to the files and directories. The default  
 is C<fig>  
   
 =item h  
   
 Display this command's parameters and options.  
   
 =back  
9    
10  =cut  =cut
11    
# Line 51  Line 17 
17  use File::Copy;  use File::Copy;
18  use File::Path;  use File::Path;
19    
20  # Get the command-line options and parameters.  print "Processing FIG directory permissions.\n";
21  my ($options, @parameters) = StandardSetup([qw() ],  Tracer::SetPermissions($FIG_Config::fig_disk, 'fig', 02664, tmp => 02777);
22                                             {  print "Processing cover page permissions.\n";
23                                              trace => [2, 'tracing level'],  Tracer::SetPermissions($FIG_Config::nmpdr_pages, 'fig', 02664);
24                                              group => ['fig', 'group to be assigned to the files'],  print "Permissions fixed.\n";
                                            },  
                                            "",  
                                            @ARGV);  
   
 if (! $parameters[0]) {  
     Trace("Current directory selected.") if T(2);  
 } elsif (! -d $parameters[0]) {  
     Confess("Invalid directory $parameters[0] specified.");  
 } else {  
     ChDir($parameters[0]);  
 }  
 Trace("Processing FIG directories.") if T(2);  
 Tracer::SetPermissions($FIG_Config::fig_disk, $options->{group}, 02664, tmp => 02777);  
 Trace("Processing cover pages.") if T(2);  
 Tracer::SetPermissions($FIG_Config::nmpdr_pages, $options->{group}, 02664);  
25    
26  1;  1;

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3