mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 01:39:16 -04:00
- Separate ports tree updating to use cvsup from cvsup-master instead of cvs
update from NFS mount, which is just way too slow
This commit is contained in:
parent
2e9b06c517
commit
46e2ac6a6f
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=234344
2 changed files with 56 additions and 6 deletions
|
@ -32,12 +32,12 @@ umask 002
|
|||
|
||||
#cvsup -g /root/cvs-supfile || finish 1
|
||||
|
||||
cd $base/ports
|
||||
fulldate=$(date)
|
||||
cvs -Rq -d ${prepo} update -PdA -D "${fulldate}"
|
||||
echo ${fulldate} > cvsdone
|
||||
snapdate=$(stamp ${fulldate})
|
||||
zfs snapshot ${zbase}/ports@${snapdate}
|
||||
#cd $base/ports
|
||||
#fulldate=$(date)
|
||||
#cvs -Rq -d ${prepo} update -PdA -D "${fulldate}"
|
||||
#echo ${fulldate} > cvsdone
|
||||
#snapdate=$(stamp ${fulldate})
|
||||
#zfs snapshot ${zbase}/ports@${snapdate}
|
||||
|
||||
cd $base/src-HEAD
|
||||
fulldate=$(date)
|
||||
|
|
50
Tools/portbuild/scripts/updatesnap.ports
Executable file
50
Tools/portbuild/scripts/updatesnap.ports
Executable file
|
@ -0,0 +1,50 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Update the master ports and source trees that are used by package builds
|
||||
# and other consumers
|
||||
|
||||
base=/a/snap
|
||||
zbase=a/snap
|
||||
|
||||
srepo=/r/ncvs
|
||||
prepo=/r/pcvs
|
||||
|
||||
supstamp() {
|
||||
fulldate=$1
|
||||
date -j -f %+ "${fulldate}" +%Y.%m.%d.%H.%M.%S
|
||||
}
|
||||
|
||||
stamp() {
|
||||
fulldate=$1
|
||||
date -j -f %+ "${fulldate}" +%Y%m%d%H%M%S
|
||||
}
|
||||
|
||||
finish() {
|
||||
err=$1
|
||||
|
||||
end=$(date +%s)
|
||||
echo "Finished at $(date)"
|
||||
len=$((end-begin))
|
||||
echo "Duration = $(date -j -f %s +%H:%M:%S ${len})"
|
||||
exit 1
|
||||
}
|
||||
|
||||
begin=$(date +%s)
|
||||
echo "Started at $(date)"
|
||||
|
||||
# We need to preserve group writability so portmgr group can write
|
||||
umask 002
|
||||
|
||||
#cvsup -g /root/cvs-supfile || finish 1
|
||||
|
||||
fulldate=$(date)
|
||||
supdate=$(supstamp ${fulldate})
|
||||
|
||||
cat /root/ports-cvsup-master-supfile | sed "s|%%DATE%%|${supdate}|" > /root/ports-cvsup-master-supfile.now
|
||||
|
||||
cvsup -L 2 /root/ports-cvsup-master-supfile.now > ${base}/ports/cvsup.log
|
||||
echo ${fulldate} > /a/snap/ports/cvsdone
|
||||
snapdate=$(stamp ${fulldate})
|
||||
zfs snapshot ${zbase}/ports@${snapdate}
|
||||
|
||||
finish 0
|
Loading…
Add table
Reference in a new issue