source: Sophya/trunk/SophyaLib/Mgr/chk_cvs.csh@ 1821

Last change on this file since 1821 was 218, checked in by ansari, 26 years ago

Creation module DPC/Mgr Reza 9/04/99

  • Property svn:executable set to *
File size: 1.3 KB
Line 
1#!/bin/csh
2
3unset A
4unset U
5unset NOS
6unset R
7if( "$1" == '-h' ) then
8 echo "usage chk_cvs.csh [-a] [-all] [-nos] [-u] [r]"
9 echo " -nos : pas de cvs status demande"
10 echo " -a : cvs status reduit pour tous les fichiers"
11 echo " -all : cvs status complet pour tous les fichiers"
12 echo " -u : update demande"
13 echo " -r : chmod a+r demande"
14 exit -1
15else
16 while( $#argv>0 )
17 if( "$1" == "-a") set A = 1
18 if( "$1" == "-all") set A = 2
19 if( "$1" == "-nos") set NOS
20 if( "$1" == "-u") set U
21 if( "$1" == "-r") set R
22 shift
23 end
24endif
25if( $?U || $?R ) set NOS
26
27set fall = (`ls -1`)
28set dcvs = ( )
29foreach f ( $fall )
30 if( -e $f/CVS ) set dcvs = ( $dcvs $f )
31end
32
33set CURDIR = `pwd`
34if( $?U ) echo "attention...... UPDATE demande"
35
36foreach d ( $dcvs )
37 if (-e $CURDIR/$d) then
38 echo " " ; echo " "
39 echo "******************************************"
40 echo " --- $d ---" ; echo " "
41 cd $CURDIR/$d
42 if( ! $?NOS ) then
43 if( $?A ) then
44 if( $A == 1 ) then
45 cvs status | grep Status
46 else if( $A == 2 ) then
47 cvs status
48 endif
49 else
50 cvs status | grep Status | grep -v "Up-to-date"
51 endif
52 endif
53 if( $?U ) cvs update
54 if( $?R ) then
55 chmod -R a+r *
56 endif
57 endif
58end
59
60cd $CURDIR
61exit 0
Note: See TracBrowser for help on using the repository browser.