Repository navigation
Expand file tree
/
Copy pathpack
More file actions
executable file
·77 lines (66 loc) · 1.98 KB
/
Copy pathpack
File metadata and controls
executable file
·77 lines (66 loc) · 1.98 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
#!/bin/bash
echo ""
echo "Start this script from a copy of GAPDoc within the GAP root you want"
echo "to use for compiling the documentation. Also,"
echo "did you adjust (yN)?: Version, Date, ArchiveURL in ./PackageInfo.g"
echo " ./version"
echo " Date. copyright date, Version in doc/gapdoc.xml"
echo " example/example.xml"
echo ""
read -n 1 start
echo
if [ $start'X' != 'yX' ]; then
echo Ok, please adjust and try again.
exit 2
fi
# the GAP version to use for building documentation (with
# relative external links)
USEGAP=/usr/local/ca/gap-rsync
CDIR=`pwd`
dirnam=GAPDoc-`cat ./version`
cd /cache
mkdir -p gaptmp
cd gaptmp
rsync -av $USEGAP/ ./
cd pkg
rm -rf GAPDoc* gapdoc*
echo "Checking out current version into /cache/gaptmp/pkg/"$dirnam" . . ."
mkdir gapdoc
cd gapdoc
cp -a $CDIR/.git .
git co master .
echo "building documentation (twice for cross refs)"
echo "" | ../../gap -r -l "../..;" makedocrel.g
echo "" | ../../gap -r -l "../..;" makedocrel.g
echo "creating test files"
rm -rf tst
mkdir tst
echo "" | ../../gap -r -l "../..;" maketest.g
echo "removing unwanted files . . ."
rm -r pack TODO clean index.html pkgreadme.css
rm -rf .git .gitignore
rm -rf */*.{log,aux,blg,brf,bbl,idx,ilg,ind,pnr} */*.xml.bib */.cvsignore
rm -f ./makedoc.g ./maketxt ./doku toweb
echo "creating archive . . ."
cd ..
mv gapdoc $dirnam
tar cf $dirnam.tar $dirnam
bzip2 -9 $dirnam.tar
echo Cleaning up
mv $dirnam.tar.bz2 $CDIR/
cd $CDIR
echo "Remove copy of GAP in /cache/gaptmp (y/n)?"
read -n 1 start
echo
if [ $start'X' == 'yX' ]; then
echo "Ok, removing ..."
rm -rf /cache/gaptmp
fi
echo New archive in ./$dirnam.tar.bz2
echo If ok then call (-win.zip no longer needed)
echo " repack.py "$dirnam".tar.bz2"
echo " rm -f "$dirnam"-win.zip"
echo "If you are happy with this archive
#tag the current state before"
echo "use the ./toweb script to update the webpage."
echo "Then change version number back to '1.dev'."