ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/gclib/scripts/svn-bio_add_dir
Revision: 305
Committed: Tue Jan 15 22:54:32 2013 UTC (11 years, 7 months ago) by gpertea
File size: 1001 byte(s)
Log Message:
some updated scripts

Line File contents
1 #!/bin/tcsh -f
2 if ("x"$1 == "x") then
3 echo "Add an existing source subdirectory to bioinformatics.org svn:\n $SVNBIO"
4 echo "Usage:\n svn-bio_add_dir <existing_dir>"
5 echo "(must be in the parent directory of <existing_dir>)"
6 exit 1
7 endif
8 set d=""
9 if ( $1 == "." ) then
10 set d=$cwd:t
11 cd ..
12 else
13 set d=$1
14 endif
15 cd $d
16 if ( $status > 0 ) then
17 echo "Directory $d not found!"
18 exit 1
19 endif
20
21 if ( -d .svn-bio ) then
22 echo "It seems that you already added $d to bioinformatics.org SVN"
23 exit 1
24 endif
25 set dn=$cwd:t
26 set dp=$cwd:h
27 svn mkdir $SVNBIO/$dn
28 if ($status != 0) then
29 echo "Error at svn mkdir $SVNBIO/$dn !"
30 exit 1
31 endif
32 set dntmp=".$dn"_tmp$$
33 svn co $SVNBIO/$dn /tmp/$dntmp
34 #rm -rf $d/.svn $d/*/.svn $d/*/*/.svn $d/*/*/*/.svn
35 mv /tmp/$dntmp/.svn .svn-bio
36 /bin/rm -rf /tmp/$dntmp
37
38 if (! -d .svn-bio) then
39 mv .svn .svn-bio
40 ln -s .svn-bio .svn
41 endif
42 #svn add Makefile
43 echo "Now go in $d and use 'svn-bio add ..' with the files you want"
44 echo " and 'svn-bio commit' when ready."

Properties

Name Value
svn:executable *