leosimons 2003/11/09 05:36:31
Added: . sign.sh local-dist.sh prepare-release.sh dist.sh
release.sh
Log:
adding release management scripts
Revision Changes Path
1.1 avalon-excalibur/sign.sh
Index: sign.sh
===================================================================
#!/bin/bash
echo =============================================================
echo hacky automated gpg signing script, by LSD
echo =======================================v0.1-Cygwin===========
echo
echo \
'Tip: Temporarily disable your passphrase to avoid typing it
a hundred times. Make sure your machine is disconnected
before you do this!
The commands go somewhat like:
gpg --edit-key <YOUR ID>
> key <YOURKEY>
> passwd
<YOUR PASSPHRASE>
<enter>
<enter>
yes
quit
yes
then run this script. After running the script, make sure you
re-enable your passphrase:
gpg --edit-key <YOUR ID>
> key <YOURKEY>
> passwd
<YOUR PASSPHRASE>
<YOUR PASSPHRASE>
quit
yes
-------------------------------------------------------------
Now signing the distributions
-------------------------------------------------------------
'
for i in component event sourceresolve store xmlutil; do
echo - Signing the $i distributions
cd $i/target/distributions
for j in `find . -type f -maxdepth 1 -name '*.zip' -or -name '*.gz'`
do
#echo gpg -v --output $j.asc --detach-sig --armor $j
gpg -v --output $j.asc --detach-sig --armor $j
done
echo - Signing the $i jars
cd ..
for j in *.jar
do
#echo gpg -v --output $j.asc --detach-sig --armor $j
gpg -v --output $j.asc --detach-sig --armor $j
done
cd ../..
done
1.1 avalon-excalibur/local-dist.sh
Index: local-dist.sh
===================================================================
#! /usr/bin/sh
echo =============================================================
echo Stupid Shell Script to grab all dists
echo =============================================================
echo Generating distributions in
echo
echo ' target/www.apache.org/dist/avalon/'
echo
echo removing old stuff...
rm -Rf target/www.apache.org
echo creating directories....
mkdir -p target/www.apache.org/dist/avalon/
cp site/etc/LICENSE.txt target/www.apache.org/dist/avalon/
DATE=`date +%Y%m%d`
#for i in \
# `find . -type d -maxdepth 1 \
# ! -name 'CVS' ! -name 'target' ! -name 'site' ! -name 'src' ! -name '\.' !
-name 'threads-tutorial'`; do
#for i in `find . -type d -maxdepth 1 -name 'connection-api' -printf '%f\n'`
for i in component event sourceresolve store xmlutil; do
echo - Deploying excalibur-$i to local distribution location
mkdir target/www.apache.org/dist/avalon/excalibur-$i
mkdir target/www.apache.org/dist/avalon/excalibur-$i/binaries
mkdir target/www.apache.org/dist/avalon/excalibur-$i/jars
mkdir target/www.apache.org/dist/avalon/excalibur-$i/source
cd $i/target/distributions
# select binaries, but not dists with a timestamp, and copy to the appropriate
location
find . -type f -maxdepth 1 \
! -name "*$DATE*" \
! -name '*-src\.*' \
-exec \
cp -f \{\}
../../../target/www.apache.org/dist/avalon/excalibur-$i/binaries/ \;
# select sources now
find . -type f -maxdepth 1 \
! -name "*$DATE*" \
-name '*-src\.*' \
-exec \
cp -f \{\} ../../../target/www.apache.org/dist/avalon/excalibur-$i/source/
\;
cd ..
# jars
find . -type f -maxdepth 1 \
! -name "*$DATE*" \
-name '*\.jar*' \
-exec \
cp -f \{\} ../../target/www.apache.org/dist/avalon/excalibur-$i/jars/ \;
# license
cd ../../target/www.apache.org/dist/avalon/excalibur-$i/
ln -s ../LICENSE.txt
cd binaries
ln -s ../LICENSE.txt
cd ../jars
ln -s ../LICENSE.txt
cd ../source
ln -s ../LICENSE.txt
# done
cd ../../../../../../
done
1.1 avalon-excalibur/prepare-release.sh
Index: prepare-release.sh
===================================================================
#! /usr/bin/sh
gpg --edit-key 'Leo Simons'
./dist.sh
./sign.sh
./local-dist.sh
gpg --edit-key 'Leo Simons'
1.1 avalon-excalibur/dist.sh
Index: dist.sh
===================================================================
#! /usr/bin/sh
echo =============================================================
echo Stupid Shell Script for maven reactor problem
echo =============================================================
echo Doing cleanup
echo -------------------------------------------------------------
#maven do-clean 2>&1 3>&1 4>&1 > dist-clean-log.txt
find . -name 'target' -or -name '8.log' -exec rm -Rf \{\} \; 2>&1 3>&1 4>&1 >
dist-build-log.txt
echo
echo Building and installing snapshot jars
echo -------------------------------------------------------------
#maven 2>&1 3>&1 4>&1 > dist-build-log.txt
curr=`pwd`
for i in component event/api event/impl sourceresolve store xmlutil; do
cd $i
maven jar:install-snapshot 2>&1 3>&1 4>&1 > $curr/$i-build-log.txt
cd $curr
done
echo
echo -------------------------------------------------------------
echo Building distributions
echo -------------------------------------------------------------
echo
#for i in \
# `find . -type d -maxdepth 1 \
# ! -name 'CVS' ! -name 'target' ! -name 'site' ! -name 'src' ! -name '\.' !
-name 'threads-tutorial'`; do
for i in component sourceresolve store xmlutil; do
cd $i
echo - BUILDING DIST for: $i > ../dist-log.txt
maven dist 2>&1 3>&1 4>&1 > ../$i-dist-log.txt
cd ..
done
# event has a different 'dist' goal...
cd event
echo - BUILDING DIST for: event > ../dist-log.txt
maven event:dist 2>&1 3>&1 4>&1 > ../event-dist-log.txt
cd ..
1.1 avalon-excalibur/release.sh
Index: release.sh
===================================================================
#! /usr/bin/sh
export RSYNC_RSH=ssh
ssh [EMAIL PROTECTED] mkdir -p ~/public_html/dist-candidates/avalon
cd target/www.apache.org/dist/avalon
rsync -vRrlpt * [EMAIL PROTECTED]:~/public_html/dist-candidates/avalon
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]