国产激情自拍_国产9色视频_丁香花在线电影小说观看 _久久久久国产精品嫩草影院

首頁 > 學院 > 操作系統(tǒng) > 正文

CVS RCS HOWTO 原始程式碼版本控制系統(tǒng) (2)

2024-07-26 00:30:59
字體:
來源:轉載
供稿:網友
--------------------------------------------------------------------------------

4. Shell Scripts 
下面的 scripts 是基本 CVS 命令的集合,而且是 Korn shell 的 scripts 。你可以把他轉成 perl 或者 bash。你可以自己修改成你想要的樣子。這些只是運用基本 CVS 命令但有些特殊的花樣加在里面。例如, sedit 這個 script 提供了檔案鎖住的功能使得其他人知道有某人正在修改這個檔案,當然你也可以直接使用 CVS 命令而不用這些 scripts ,這些 scripts 只是在展示 CVS 是多麼的有彈性。 

把這些 scripts 復制到 /usr/local/bin 下,并且此目錄應該在你的 PATH 環(huán)境變數中。 

sget [-r revision_number]  要從 CVS 獲得一個唯讀檔案或整個唯讀目錄,請按 sget 
sedit [-r revision_number]  要修改一個一個程式碼時,這個 scripts 會做檔案鎖住的動作,因此沒有別人可以登出這個檔案了。當然你可以改變這個 script 成你想要的功能 - 例如不鎖住,只出現警告訊息,或者相反的,非常嚴謹的鎖檔案。請按 sedit 
scommit [-r revision_number]  要交出某個你修改的檔案或整個目錄。 把你的改變交給 CVS。請按 scommit 
supdate  要藉由從 CVS 得到最新的檔案來update 一個檔案或整個目錄。請按 supdate 
sunlock [-r revision_number]  要把因為用 sedit 後的檔案鎖關掉。這會釋放檔案鎖(Release File Lock)。請按 sunlock 
slist 要看目前正被你修改的檔案列表。做 'ls -l | grep | ...' 命令,請按 slist 
sinfo  要得到一個檔案的改版資訊。 請按 sinfo 
slog  要得到一個 CVS 檔案改版的歷史紀錄,請按 slog 
sdif  
sdif -r rev1 -r rev2  要得到你的檔案與 CVS 柜子里的檔案不同的地方在哪里。請按 sdif 

注意: sdif 只有一個 'f' ,因為這里已經有一個 unix 命令叫 'sdiff'。 


sadd  要新增一個檔案到 CVS 柜子里。請按 sadd 
sdelete  要從 CVS 柜子里清掉一個檔案。請按 sdelete 
sfreeze   要凍結原始碼 (freeze codes) ,這是將要發(fā)行 (release) 整個原始碼目錄樹。請按 sfreeze 
saddtree   要新增一個目錄樹到 CVS 。請按 saddtree 
例如 : 


--------------------------------------------------------------------------------

        cd $HOME;   
        sfreeze REVISION_1_0  srctree  


--------------------------------------------------------------------------------
這將會凍結原始碼,并貼上一個標簽 REVISION_1_0 ,如此一來你就可以稍後用版本名字登出整個目錄樹。 

                ******************************************************



4.1 sget 
注意 : Korn shell /bin/ksh 在你從linux CD-ROM 安裝 pdksh*.rpm 時就會產生 

請把他存成一般文字檔并改變存取權限 chmod a+rx 



--------------------------------------------------------------------------------

#!/bin/ksh

# CVS PRogram sget
# Program to check out the file from CVS read-only

cmdname=`basename $0`

Usage()
{
        print "/nUsage: $cmdname [-r revision_number/symbolic_tag_name]  "
        print "The options -r are optional "
        print "For example - "
        print " $cmdname -r 1.1 foo.cpp"
        print " $cmdname foo.cpp "
        print " $cmdname some_directory "
        print "Extract by symbolic revision tag like - "
        print " $cmdname -r REVISION_1 some_directory "
        print " "
        exit
}

# Command getopt will not supported in next major release. 
# Use getopts instead. 
while getopts r: ii
do
        case $ii in
        r) FLAG1=$ii; OARG1="$OPTARG";;
        ?) Usage; exit 2;;
        esac
done
shift ` expr $OPTIND - 1 `

#echo FLAG1 = $FLAG1 , OARG1 = $OARG1

if [ $# -lt 1 ]; then
        Usage
fi

bkextn=sget_bak

hme=` echo $HOME | cut -f1 -d' '  `
if [ "$hme" = "" ]; then
        print "/nError: /$HOME is not set!!/n"
        exit
fi

# Check if file already exists....
if [ -f $1 ]; then
        user_perms=" "
        group_perms=" "
        other_perms=" "
        user_perms=`ls -l $1 | awk '{print $1 }' | cut -b3-3 `
        group_perms=`ls -l $1 | awk '{print $1 }' | cut -b6-6 `
        other_perms=`ls -l $1 | awk '{print $1 }' | cut -b9-9 `
        if [ "$user_perms" = "w" -o "$group_perms" = "w"  /
                -o "$other_perms" = "w" ]; then
                print "/nError: The file is writable. Aborting $cmdname ......"
                print "       You should either backup, scommit or delete the file and"
                print "       try $cmdname again/n"
                exit
        fi
fi

cur_dir=`pwd`
#echo $cur_dir

len=${#hme}
len=$(($len + 2))
#echo $len

subdir=` echo $cur_dir | cut -b $len-2000 `
#echo $subdir

if [ "$subdir" = "" ]; then
        fdname=$1
else
        fdname=$subdir"/"$1
fi

# Move the file
touch $1 2>/dev/null
/mv -f $1 $1.$bkextn

# Create subshell
(
cd $hme
#echo $fdname

# Use -A option to clear all sticky flags
if [ "$FLAG1" = "" ]; then
        cvs -r checkout -A $fdname
else
        cvs -r checkout -A -$FLAG1 $OARG1 $fdname
fi
)
#pwd

if [ -f $1 ]; then
        print "/nREAD-ONLY copy of the file $fdname obtained."
        print "Done $cmdname"
        #print "/nTip (Usage): $cmdname  /n"
fi


--------------------------------------------------------------------------------

4.2 sedit 
注意 : Korn shell /bin/ksh 在你從Linux CD-ROM 安裝 pdksh*.rpm 時就會產生 

請把他存成一般文字檔并改變存取權限 chmod a+rx 



--------------------------------------------------------------------------------

#!/bin/ksh
# CVS program sedit
# Program to check out the file from CVS read/write mode with locking

cmdname=`basename $0`

Usage()
{
#       print "/nUsage: $cmdname [-r revision_number] [-F] "
#       print "The options -r, -F are optional "
#       print "The option -F is FORCE edit even if file is "
#       print "locked by another developer"

        print "/nUsage: $cmdname [-r revision_number] "
        print "The options -r are optional "

        print "For example - "
        print " $cmdname -r 1.1 foo.cpp"
        print " $cmdname foo.cpp "
#       print " $cmdname -F foo.cpp "
        print " "
}

# Command getopt will not supported in next major release. 
# Use getopts instead. 
#while getopts r:F ii
while getopts r: ii
do
        case $ii in
        r) FLAG1=$ii; OARG1="$OPTARG";;
#       F) FLAG2=$ii; OARG2="$OPTARG";;
        ?) Usage; exit 2;;
        esac
done
shift ` expr $OPTIND - 1 `

#echo FLAG1 = $FLAG1 , OARG1 = $OARG1

if [ $# -lt 1 ]; then
        Usage
        exit
fi

hme=` echo $HOME | cut -f1 -d' '  `
if [ "$hme" = "" ]; then
        print "/nError: /$HOME is not set!!/n"
        exit
fi

bkextn=sedit_bak

cur_dir=`pwd`
#echo $cur_dir

len=${#hme}
len=$(($len + 2))
#echo $len

subdir=` echo $cur_dir | cut -b $len-2000 `
#echo $subdir

if [ "$subdir" = "" ]; then
        fdname=$1
else
        fdname=$subdir"/"$1
fi

# If file is already checked out by another developer....
cvs_root=` echo $CVSROOT | cut -f1 -d' '  `
if [ "$cvs_root" = "" ]; then
        print "/nError: /$CVSROOT is not set!!/n"
        exit
fi
cldir=$CVSROOT/$subdir/Locks
mkdir $cldir 2>/dev/null
rcsfile=$CVSROOT/$subdir/$1,v
#echo $rcsfile

if [ ! -e $rcsfile ]; then
        print "/nError: File $1 does not exist in CVS repository!!/n"
        exit
fi

# Get the tip revision number of the file....
# Use tmpfile as the arg cannot be set inside the sub-shell
tmpfile=$hme/sedit-lock.tmp
/rm -f $tmpfile 2>/dev/null
if [ "$FLAG1" = "" ]; then
        (
        cd $hme
        cvs log $fdname | head -6 | grep head: | awk '{print $2}' > $tmpfile 
        )
        OARG1=`cat $tmpfile`
        /rm -f $tmpfile 2>/dev/null
fi

lockfile=$cldir/$1-$OARG1
#if [ -e $lockfile -a "$FLAG2" = "" ]; then
if [ -e $lockfile ]; then
        print "/nError: File $1 Revision $OARG1 already locked by another developer !!"
        aa=` ls -l $lockfile | awk '{print "Locking developers unix login name is = " $3}' `
        print $aa
        print "That developer should do scommit OR sunlock to release the lock"
        print " "
#       print "You can also use -F option to force edit the file even if"
#       print "the file is locked by another developer. But you must talk to"
#       print "other developer to work concurrently on this file." 
#       print "For example - this option is useful if you work on a seperate"
#       print "C++ function in the file which does not interfere with other"
#       print "developer."
#       print " "
        exit
fi

# Get read-only copy now....
if [ ! -e $1 ]; then
        (
        cd $hme
        cvs -r checkout $fdname 1>/dev/null
        )
fi

# Check if file already exists....
if [ -f $1 ]; then
        user_perms=" "
        group_perms=" "
        other_perms=" "
        user_perms=`ls -l $1 | awk '{print $1 }' | cut -b3-3 `
        group_perms=`ls -l $1 | awk '{print $1 }' | cut -b6-6 `
        other_perms=`ls -l $1 | awk '{print $1 }' | cut -b9-9 `
        if [ "$user_perms" = "w" -o "$group_perms" = "w"  /
                -o "$other_perms" = "w" ]; then
                print "/nError: The file is writable. Aborting $cmdname ......"
                print "       You must backup, scommit or delete file and"
                print "       try $cmdname again/n"
                exit
        fi
        #print "/nNote: The file $1 is read-only."
        #print "Hence I am moving it to $1.$bkextn ..../n"
        /mv -f $1 $1.$bkextn
        chmod 444 $1.$bkextn
elif [ -d $1 ]; then
        print "/nError: $1 is a directory and NOT a file. Aborting $cmdname ..../n"
        exit
fi

# Create subshell
print "/nNow getting the file $1 from CVS repository .../n"
(
cd $hme
#echo $fdname
# Use -A option to clear the sticky tag and to get 
# the HEAD revision version
if [ "$FLAG1" = "" ]; then
        cvs -w checkout -A $fdname
else
        cvs -w checkout -A -$FLAG1 $OARG1 $fdname
fi
)

if [ -e $1 ]; then
        touch $lockfile
fi

#pwd

print "/nDone $cmdname"
#print "/nTip (Usage): $cmdname  /n"


--------------------------------------------------------------------------------

4.3 scommit 
注意 : Korn shell /bin/ksh 在你從Linux CD-ROM 安裝 pdksh*.rpm 時就會產生 

請把他存成一般文字檔并改變存取權限 chmod a+rx 



--------------------------------------------------------------------------------

#!/bin/ksh
# CVS program scommit
# Program to commit the changes and check in the file into CVS

cmdname=`basename $0`

Usage()
{
        print "/nUsage: $cmdname [-r revision_number] "
        print "The options -r are optional "
        print "For example - "
        print " $cmdname -r 1.1 foo.cpp"
        print " $cmdname foo.cpp "
        print " "
}

# Command getopt will not supported in next major release. 
# Use getopts instead. 
while getopts r: ii
do
        case $ii in
        r) FLAG1=$ii; OARG1="$OPTARG";;
        ?) Usage; exit 2;;
        esac
done
shift ` expr $OPTIND - 1 `

#echo FLAG1 = $FLAG1 , OARG1 = $OARG1

if [ $# -lt 1 ]; then
        Usage
        exit 2
fi

if [ -d $1 ]; then
        Usage
        exit 2
fi

hme=` echo $HOME | cut -f1 -d' '  `
if [ "$hme" = "" ]; then
        print "/nError: /$HOME is not set!!/n"
        exit
fi

# Find sub-directory
cur_dir=`pwd`
#echo $cur_dir
len=${#hme}
len=$(($len + 2))
#echo $len
subdir=` echo $cur_dir | cut -b $len-2000 `
#echo $subdir
if [ "$subdir" = "" ]; then
        fdname=$1
else
        fdname=$subdir"/"$1
fi

# If file is already checked out by another user....
cvs_root=` echo $CVSROOT | cut -f1 -d' '  `
if [ "$cvs_root" = "" ]; then
        print "/nError: /$CVSROOT is not set!!/n"
        exit
fi
cldir=$CVSROOT/$subdir/Locks
mkdir $cldir 2>/dev/null

# Get the working revision number of the file....
# Use tmpfile as the arg cannot be set inside the sub-shell
tmpfile=$hme/sedit-lock.tmp
/rm -f $tmpfile 2>/dev/null
if [ "$FLAG1" = "" ]; then
        (
        cd $hme
        cvs status $fdname 2>/dev/null | grep "Working revision:" | awk '{print $3}' >$tmpfile
        )
        OARG1=`cat $tmpfile`
        /rm -f $tmpfile 2>/dev/null
fi

if [ "$OARG1" = "" ]; then
        print "The file $fdname is NEW, it is not in the CVS repository"
else
        lockfile=$cldir/$1-$OARG1
        if [ -e $lockfile ]; then
                # Check if this revision is owned by you...
                aa=` ls -l $lockfile | awk '{print $3}' `
                userid=`id | cut -d'(' -f2 | cut -d')' -f1 `
                if [ "$aa" != "$userid" ]; then
                        print " "
                        print "The file $fdname is NOT locked by you!!"
                        print "It is locked by unix user name $aa and your login name is $userid"
#                       print "If you are working concurrently with other developer"
#                       print "and you used -F option with sedit."
                        print "You need to wait untill other developer does scommit"
                        print "or sunlock"
                        print "Aborting the $cmdname ...."
                        print " "
                        exit 2
                fi
        else
                if [ -f $CVSROOT/$subdir/$1,v ]; then
                        print "You did not lock the file $fdname with sedit!!"
                        print "Aborting the $cmdname ...."
                        exit 2 
                else
                        print "/nThe file $fdname does not exist in CVS repository yet!!"
                        print "You should have done sadd on $fdname ...."
                fi
        fi
fi

if [ -d $1 ]; then
        Usage
        exit 2
        # Do not allow directory commits for now ...
        #cvs commit
else
        cvs commit $1
        exit_status=$?
fi

if [ $exit_status -eq 0 ]; then
        print "/nDone $cmdname. $cmdname successful"
        #print "/nTip (Usage): $cmdname /n"
fi


--------------------------------------------------------------------------------

4.4 supdate 
注意 : Korn shell /bin/ksh 在你從Linux CD-ROM 安裝 pdksh*.rpm 時就會產生 

請把他存成一般文字檔并改變存取權限 chmod a+rx 



--------------------------------------------------------------------------------

#!/bin/ksh

# CVS program supdate
# Program to update the file from CVS read/write mode

cmdname=`basename $0`

if [ $# -lt 1 ]; then
        print "/nUsage: $cmdname "
        exit
fi

# Check if file already exists....
if [ $# -gt 0 -a  -f $1 ]; then
        user_perms=" "
        group_perms=" "
        other_perms=" "
        user_perms=`ls -l $1 | awk '{print $1 }' | cut -b3-3 `
        group_perms=`ls -l $1 | awk '{print $1 }' | cut -b6-6 `
        other_perms=`ls -l $1 | awk '{print $1 }' | cut -b9-9 `
        if [ "$user_perms" = "w" -o "$group_perms" = "w"  /
                -o "$other_perms" = "w" ]; then
                while :
                do
                        print "/n$cmdname will backup your working file "
                        print "$1 to $1.supdate_bak before doing any merges."
                        print "Are you sure you want the merge the changes from"
                        print -n "CVS repository to your working file ?  [n]: "
                        read ans
                        if [ "$ans" = "y" -o "$ans" = "Y" ]; then
                                if [ -f $1.supdate_bak ]; then
                                        print "/nWarning : File $1.supdate_bak already exists!!"
                                        print "Please examine the file $1.supdate_bak and delete it"
                                        print "and than re-try this $cmdname "
                                        print "Aborting $cmdname ...."
                                        exit
                                else
                                        cp $1 $1.supdate_bak
                                        break
                                fi
                        elif [ "$ans" = "n" -o "$ans" = "N" -o "$ans" = "" -o "$ans" = " " ]; then
                                exit
                        fi
                done
        fi
fi

if [ -d $1 ]; then
        print "/nDirectory update is disabled as cvs update"
        print "merges the changes from repository to your working directory"
        print "So give the filename to update - as shown below: "
        print " Usage: $cmdname "
        exit
#       cvs update
else
        cvs update $1
fi

print "/nDone $cmdname. $cmdname successful"
#print "/nTip (Usage): $cmdname /n"


--------------------------------------------------------------------------------

4.5 sunlock 
注意 : Korn shell /bin/ksh 在你從Linux CD-ROM 安裝 pdksh*.rpm 時就會產生 

請把他存成一般文字檔并改變存取權限 chmod a+rx. 



--------------------------------------------------------------------------------

#!/bin/ksh
# CVS program sunlock
# Program to unlock the file to release the lock done by sedit

cmdname=`basename $0`

Usage()
{
        print "/nUsage: $cmdname [-r revision_number] "
        print " The options -r is optional "
        print "For example - "
        print " $cmdname -r 1.1 foo.cpp"
        print " $cmdname foo.cpp "
        print " "
}

# Command getopt will not supported in next major release. 
# Use getopts instead. 
while getopts r: ii
do
        case $ii in
        r) FLAG1=$ii; OARG1="$OPTARG";;
        ?) Usage; exit 2;;
        esac
done
shift ` expr $OPTIND - 1 `

if [ $# -lt 1 ]; then
        Usage
        exit
fi

hme=` echo $HOME | cut -f1 -d' '  `
if [ "$hme" = "" ]; then
        print "/nError: /$HOME is not set!!/n"
        exit
fi

cur_dir=`pwd`
#echo $cur_dir

len=${#hme}
len=$(($len + 2))
#echo $len

subdir=` echo $cur_dir | cut -b $len-2000 `
#echo $subdir

if [ "$subdir" = "" ]; then
        fdname=$1
else
        fdname=$subdir"/"$1
fi

# If file is already checked out by another user....
cvs_root=` echo $CVSROOT | cut -f1 -d' '  `
if [ "$cvs_root" = "" ]; then
        print "/nError: /$CVSROOT is not set!!/n"
        exit
fi
cldir=$CVSROOT/$subdir/Locks
rcsfile=$CVSROOT/$subdir/$1,v
#echo $rcsfile

if [ ! -e $rcsfile ]; then
        print "/nError: File $1 does not exist in CVS repository!!/n"
        exit
fi

# Get the tip revision number of the file....
# Use tmpfile as the arg cannot be set inside the sub-shell
tmpfile=$hme/sedit-lock.tmp
/rm -f $tmpfile 2>/dev/null
if [ "$FLAG1" = "" ]; then
        (
        cd $hme
        cvs log $fdname | head -6 | grep head: | awk '{print $2}' > $tmpfile 
        )
        OARG1=`cat $tmpfile`
        /rm -f $tmpfile 2>/dev/null
fi

lockfile=$cldir/$1-$OARG1
#echo lockfile is : $lockfile
if [ ! -e $lockfile ]; then
        print "/nFile $1 revision $OARG1 is NOT locked by anyone"
        print " "
        exit 
fi

ans=""
while :
do
        print "/n/n***************************************************"
        print "WARNING: $cmdname will release lock and enable other"
        print "         developers to edit the file. It is advisable"
        print "         to save your changes with scommit command"
        print "***************************************************"
        print -n "/nAre you sure you want to unlock the file ? [n]: "
        read ans
        if [ "$ans" = "" -o "$ans" = " " -o "$ans" = "n" -o "$ans" = "N" ]; then
                print "/nAborting $cmdname ...."
                exit
        fi
        if [ "$ans" = "y" -o "$ans" = "Y" ]; then
                print "/n/n/n/n/n "
                print "CAUTION: You may lose all the changes made to file!!"
                print -n "Do you really want to unlock the file ? [n]: "
                read ans
                if [ "$ans" = "y" -o "$ans" = "Y" ]; then
                        break
                else
                        exit
                fi
        else
                print "/n/nWrong entry. Try again..."
                sleep 1
        fi
done

if [ -e $lockfile ]; then
        /rm -f $lockfile
        print "/nDone $cmdname"
else
        print "/nFile $1 is NOT locked by anyone"
        print " "
fi


--------------------------------------------------------------------------------

4.6 slist 
注意 : Korn shell /bin/ksh 在你從Linux CD-ROM 安裝 pdksh*.rpm 時就會產生 

請把他存成一般文字檔并改變存取權限 chmod a+rx 



--------------------------------------------------------------------------------

#!/bin/ksh

# CVS program slist
# Program to list all edited source files from CVS

#cmdname=`basename $0`

#echo "no of params : " $#
#echo "all args : " $@

recurse_flag=""

if [ "$1" = "" ]; then
        dir=.
        recurse_flag=""
else
        dir=$@
        recurse_flag=" -prune "
fi

FOUT=slist_temporary_file.out

/rm -f $FOUT

find $dir  $recurse_flag -type f -exec ls -ltr {} /; /
| grep -v "/CVS/" /
| grep ^/-rw /
| grep -v //.o /
| grep -v //.log /
| grep -v //.out /
| grep -v //.pid /
| awk '{ if ($NF != "tags") print $0 }' /
| awk '{ if ($NF != "a.out") print $0 }' /
| awk '{ if ($NF != "core") print $0 }' /
| awk '{ print $NF }' > $FOUT

aa=`cat $FOUT`
/rm -f $FOUT

for ii in $aa ; do
        ftype=" "
        ftype=`file $ii | awk '{print $2 }' `

        # find . -type f -exec file {} /;
        # 1)ELF 2)commands 3)[nt]roff, 4)c 5)English  6)executable
        # 7)ascii 8)current 9)empty
        # Binaries are ELF, lib.a are current
        #
        if [ "$ftype" = "ascii" -o "$ftype" = "commands" /
                -o "$ftype" = "[nt]roff," -o "$ftype" = "c" -o "$ftype" = "data" /
                -o "$ftype" = "English" -o "$ftype" = "executable" ]; then
                pcfile=` echo $ii | cut -d'.' -f1`
                pcfile=${pcfile}".pc"
                if [ ! -f $pcfile ]; then
                        ls -l $ii
                else
                        if [ "$ii" = "$pcfile" ]; then
                                ls -l $ii
                        fi
                fi
        fi
done;

#| grep -v ^/-rwx /

#ls -l | grep ^/-rw | grep -v //.o
#ls -l | grep ^/-rw | grep -v //.o | awk '{ if ($NF != "tags") print $0 }'
#ls -l | grep ^/-rw | grep -v ^/-rwx | grep -v //.o |  awk '{ if ($NF != "tags") print $0 }' | awk '{ if ($NF != "core") print $0 }'

#print "/nDone $cmdname. $cmdname successful"
#print "/nTip (Usage): $cmdname /n"


--------------------------------------------------------------------------------

4.7 sinfo 
注意 : Korn shell /bin/ksh 在你從Linux CD-ROM 安裝 pdksh*.rpm 時就會產生 

請把他存成一般文字檔并改變存取權限 chmod a+rx 



--------------------------------------------------------------------------------

#!/bin/ksh

# CVS program sinfo
# Program to get the status of files in working directory

cmdname=`basename $0`

if [ $# -lt 1 ]; then
        print "/nUsage: $cmdname [file/directory name] "
        print "For example - "
        print " $cmdname foo.cpp"
        print " $cmdname some_directory "
        print " "
        exit
fi

hme=` echo $HOME | cut -f1 -d' '  `
if [ "$hme" = "" ]; then
        print "/nError: /$HOME is not set!!/n"
        exit
fi

tmpfile=$hme/cvs_sinfo.tmp
rm -f $tmpfile

cur_dir=`pwd`
#echo $cur_dir

len=${#hme}
len=$(($len + 2))
#echo $len

subdir=` echo $cur_dir | cut -b $len-2000 `
#echo $subdir

if [ "$subdir" = "" ]; then
        fdname=$1
else
        fdname=$subdir"/"$1
fi

# Create subshell
if [ -f $1 ]; then
        (
        cd $hme
        clear
        cvs status $fdname 
        )
elif [ -d $1 ]; then
        (
        cd $hme
        clear
        echo "  " >> $tmpfile
        echo "  ****************************************" >> $tmpfile
        echo "        Overall Status of Directory" >> $tmpfile
        echo "  ****************************************" >> $tmpfile
        cvs release $fdname 1>>$tmpfile 2>>$tmpfile << EOF
Y
EOF
        echo "/n   -------------------------------/n" >> $tmpfile

        aa=`cat $tmpfile | grep ^"M " | awk '{print $2}' `
        for ii in $aa 
        do
                jj="(cd $hme; cvs status $subdir/$ii );"
                echo $jj | /bin/sh  /
                        | grep -v Sticky | awk '{if (NF != 0) print $0}' /
                        1>>$tmpfile 2>>$tmpfile 
        done

        cat $tmpfile | grep -v ^? | grep -v "Are you sure you want to release" /
        | less
        rm -f $tmpfile
        )
else
        print "/nArgument $1 if not a file or directory"
        exit
fi


--------------------------------------------------------------------------------

4.8 slog 
注意 : Korn shell /bin/ksh 在你從Linux CD-ROM 安裝 pdksh*.rpm 時就會產生 

請把他存成一般文字檔并改變存取權限 chmod a+rx 



--------------------------------------------------------------------------------

#!/bin/ksh

# CVS program slog
# Program to list history of the file in CVS 

cmdname=`basename $0`

if [ $# -lt 1 ]; then
        print "/nUsage: $cmdname  /n"
        exit
fi

# Check if file does not exist....
if [ ! -f $1 ]; then
        print "/nError: $1 is NOT a file. Aborting $cmdname ......"
        exit
fi

cvs log $1 | /usr/local/bin/less

print "/nDone $cmdname. $cmdname successful"
#print "/nTip (Usage): $cmdname /n"


--------------------------------------------------------------------------------

4.9 sdif 
注意 : Korn shell /bin/ksh 在你從Linux CD-ROM 安裝 pdksh*.rpm 時就會產生 

請把他存成一般文字檔并改變存取權限 chmod a+rx 



--------------------------------------------------------------------------------

#!/bin/ksh

# CVS program sdif
# Program to see difference of the working file with CVS copy

cmdname=`basename $0`

Usage()
{
        print "/nUsage: $cmdname  "
        print "$cmdname -r -r  /n"
        exit
}
FLAG1=""
FLAG2=""
OARG1=""
OARG2=""
# Command getopt will not supported in next major release. 
# Use getopts instead. 
while getopts r:r: ii
do
        case $ii in
        r) 
                if [ "$FLAG1" = "" ]; then
                        FLAG1=$ii; 
                        OARG1="$OPTARG"
                else
                        FLAG2=$ii; 
                        OARG2="$OPTARG"
                fi
                ;;
        ?) Usage; exit 2;;
        esac
done
shift ` expr $OPTIND - 1 `

if [ "$FLAG2" = "" ]; then
        FLAG2=r
        OARG2=HEAD
fi

if [ "$FLAG1" = "" ]; then
        cvs diff -r HEAD $1 | less
else
        cvs diff -$FLAG1 $OARG1 -$FLAG2 $OARG2 $1 | less
fi


--------------------------------------------------------------------------------

4.10 sadd 
注意 : Korn shell /bin/ksh 在你從Linux CD-ROM 安裝 pdksh*.rpm 時就會產生 

請把他存成一般文字檔并改變存取權限 chmod a+rx 



--------------------------------------------------------------------------------

#!/bin/ksh

# test
# CVS program sadd
# Program to add the file to CVS

cmdname=`basename $0`
if [ $# -lt 1 ]; then
        print "/nUsage: $cmdname  /n"
        exit
fi

# Check if file exists ....
if [ -f $1 ]; then
        cvs add $1
        exit
fi

if [ ! -d $1 ]; then
&n
發(fā)表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發(fā)表
国产激情自拍_国产9色视频_丁香花在线电影小说观看 _久久久久国产精品嫩草影院
91sp网站在线观看入口| 青青草在线免费观看| 国产在线色视频| 久久香蕉一区| 中文字幕视频免费在线观看| 天堂资源最新版在线视频观看免费网 | 国产一级片在线| 国产一二在线观看| 在线免费日韩| 狠狠操五月天| 国产成+人+亚洲+欧美+综合| 国产亚洲精品久久久久久青梅 | 国产视频一二三区| av中文天堂在线| 国产亚洲精品自在线观看| 在线观看中文字幕| 天天操天天艹| h视频在线网站| 国产成人高清精品| 超碰免费在线观看| 亚洲免费国产| 国产三区四区在线观看| www.91在线播放| 精品欧美不卡一区二区在线观看| 欧美性猛交xxxx免费看久久| 国产91在线视频蝌蚪| 国产麻豆视频网站| www.狠狠操.com| av大片在线播放| 国产精品乱码一区二区三区视频 | 在线观看的网站你懂的| 国产欧美一区二区三区小说| 久草视频国产| av二区三区| 在线亚洲不卡| 精品一二三四| 99re热在线观看| 伊人影院在线观看| 91涩漫在线观看c| 国产精品二线| 国产aa视频| 精品视频vs精品视频| 国产传媒在线播放| 国产对白国语对白| 国产精品入口麻豆免费观看| 国产午夜精品久久久久免费视 | 久热精品免费视频| 人人干人人插| 老鸭窝av在线| 国产精选在线视频拍拍拍| 国产免费永久在线观看| 国产免费av高清在线| 五月天天在线| 国产成人夜间影院在线观看| 国产区在线观看| 91精品专区| 阿v免费在线观看| 久久99亚洲网美利坚合众国| 天天操天天艹| 在线成人一区| 国产乱码在线| 国产视频精选在线| 精品黄色免费中文电影在线播放| 亚洲综合在线不卡| 黄色电影网站在线观看| 国产精品视频一区二区久久| 四虎成年永久免费网站| 中文字幕中文字幕在线中高清免费版 | 日本最新在线视频| 最近高清中文在线字幕在线观看 | 88av在线| av在线不卡免费| 国产一区精品| 在线观看中文字幕| 国产夫妻视频| 五月伊人六月| a视频在线播放| 中文字幕在线视频网| 亚洲夜夜综合| 国产高清免费av在线| 免费电影网站在线视频观看福利| 国产小视频在线播放| 亚洲一道本在线| 国产精品乱码一区二区三区视频| 日本啊v在线| 四虎在线免费视频| 91涩漫在线观看c| 国产情侣高潮对白| 丁香综合五月| 欧美日韩亚洲国内综合网 | 性欧美精品xxxx| 91视频久色| 国产精品久久久久久福利| 国产毛片毛片| 激情网站在线| 日本三级在线视频| 91蜜桃在线视频| 在线视频中文字幕| 在线观看av网站永久| 国产高清在线a视频大全| 国产亚洲依依| 国产亚洲精品久久久网站好莱| 国产免费黄色| 国产精品㊣新片速递bt| 国产专区在线| 1区不卡电影| 精品视频vs精品视频| 在线视频三级| 日本不卡1区2区3区| 免费a级人成a大片在线观看| 日本福利午夜视频在线| 四虎免费播放| 国产精品一品| 国产高清在线观看| eeuss影院在线观看| 久久国产热视频| 国产无遮挡在线视频免费观看| 国产网站在线免费观看| 99re6在线视频精品免费| 日本综合一区二区三区| 天天av天天爽| 亚洲成a人v欧美综合天堂麻豆| 欧美日韩一区二区三区在线播放| 丁香花视频在线观看| 国产精品久久久久久久牛牛 | 伊人电影在线观看| 噜噜噜噜噜在线视频| 国产精品视频流白浆免费视频| 在线观看精品视频一区二区三区| 九九热视频在线观看| 国产99re| 非洲黑人最猛性xxxx交| 在线观看精品一区二区三区| 尤物视频网站在线观看| 天天操中文字幕视频| 国产视频精品久久| 青青草视频免费在线观看| 国产一级黄色电影| 亚洲精品乱码电影在线观看| 成视频年人免费看黄网站| 在线观看wwww| 国产成人天天5g影院| 国产精品自拍亚洲| 欧美xxxx黑人又粗又长| 在线中文资源天堂| 国产三级在线免费| 国产麻豆精品高清在线播放| heisi视频网在线观看| 精品国产一区二区三区不卡在线 | 国产调教视频在线观看| 日本在线天堂| 在线欧美一级视频| 国产盗摄一区二区| 国产精品久久在线| 天堂中文资源在线| 高清av中文在线字幕观看1| 欧美精品一区二区三区免费| av在线免费播放网站| 在线国产一级| av网站在线播放| 在线免费观看高清视频色| 国产不卡一卡2卡三卡4卡5卡在线| 国产一二三区在线视频| 中文字幕高清av| 1区2区3区在线| **三级三级97片毛片| 天堂资源在线中文| 中文字幕国产欧美| 国产成人精品综合网站| 在线天堂中文www视软件| 在线中文资源天堂| 日本高清中文字幕在线| 欧美韩日国产| 中文字幕在线观看av| 国产精品蜜臀| 亚洲尤物在线视频| 免费在线你懂的| 最近中文字幕mv2018在线高清 | 国产精品免费视频二三区| 国产精品伦理一区二区三区| 国产激情三区| 亚洲а∨精品天堂在线| 国内自拍视频在线看免费观看| 成人精品福利| 精品国产白色丝袜高跟鞋| 午夜性爽视频男人的天堂| 青青草免费在线观看| 中文字幕国产欧美| 亚洲一本大道| 五月婷婷开心综合| av麻豆国产| 国产网站免费观看| 青青九九免费视频在线| 五月婷婷视频在线观看| av在线网页| 国产高清在线a视频大全| 狠狠干婷婷色| 亚洲最新永久观看在线| 国产私人影院| 国产又色又爽又黄刺激在线视频|