2000-05-09 15:00:50 +04:00
|
|
|
#!/bin/sh
|
|
|
|
#
|
2013-01-04 23:01:54 +04:00
|
|
|
# Copyright (C) 1999-2013 The ViewCVS Group. All Rights Reserved.
|
2000-05-09 15:00:50 +04:00
|
|
|
#
|
|
|
|
# By using this file, you agree to the terms and conditions set forth in
|
2005-12-17 20:19:28 +03:00
|
|
|
# the LICENSE.html file which can be found at the top level of the ViewVC
|
|
|
|
# distribution or at http://viewvc.org/license-1.html.
|
2000-05-09 15:00:50 +04:00
|
|
|
#
|
2006-03-18 05:07:36 +03:00
|
|
|
# For more information, visit http://viewvc.org/
|
2000-05-09 15:00:50 +04:00
|
|
|
#
|
|
|
|
# -----------------------------------------------------------------------
|
|
|
|
#
|
2005-12-17 20:19:28 +03:00
|
|
|
# make-release: internal tool for creating ViewVC releases
|
2000-05-09 15:00:50 +04:00
|
|
|
#
|
|
|
|
# -----------------------------------------------------------------------
|
|
|
|
#
|
|
|
|
|
2005-11-12 10:06:54 +03:00
|
|
|
### Validate input
|
|
|
|
if test $# != 2 && test $# != 1; then
|
2009-04-20 21:40:51 +04:00
|
|
|
echo "Usage: $0 TARGET-DIRECTORY [BRANCH]"
|
2005-11-12 10:06:54 +03:00
|
|
|
echo ""
|
2009-04-20 21:40:51 +04:00
|
|
|
echo "If BRANCH (i.e. \"tags/1.1.0\" or \"branches/1.0.x\") is not provided,"
|
|
|
|
echo "the release will be rolled from trunk."
|
2000-05-09 15:00:50 +04:00
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2005-11-12 10:06:54 +03:00
|
|
|
TARGET=${1}
|
2009-04-20 21:38:57 +04:00
|
|
|
if test $# = 1; then
|
2005-11-12 10:06:54 +03:00
|
|
|
ROOT=trunk
|
|
|
|
else
|
2009-04-20 21:38:57 +04:00
|
|
|
ROOT=${2}
|
2005-11-12 10:06:54 +03:00
|
|
|
fi
|
|
|
|
|
|
|
|
if test -e ${TARGET}; then
|
|
|
|
echo "ERROR: must remove ${TARGET} first."
|
2001-05-30 13:19:18 +04:00
|
|
|
exit 1
|
|
|
|
fi
|
2000-05-09 15:00:50 +04:00
|
|
|
|
2005-11-12 10:06:54 +03:00
|
|
|
### Grab an export from the Subversion repository.
|
2009-04-20 21:38:57 +04:00
|
|
|
EXPORT_URL="http://viewvc.tigris.org/svn/viewvc/${ROOT}"
|
|
|
|
echo "Exporting '${EXPORT_URL}' into '${TARGET}'"
|
2005-11-12 10:06:54 +03:00
|
|
|
|
2006-04-06 21:22:39 +04:00
|
|
|
for PLATFORM in unix windows; do
|
|
|
|
if test ${PLATFORM} = windows; then
|
|
|
|
EOL="--native-eol CRLF"
|
|
|
|
else
|
|
|
|
EOL="--native-eol LF"
|
|
|
|
fi
|
2000-05-09 15:00:50 +04:00
|
|
|
|
2007-04-10 11:04:51 +04:00
|
|
|
echo "Beginning build for ${PLATFORM}:"
|
|
|
|
|
|
|
|
echo " Exporting source code..."
|
2009-04-20 21:38:57 +04:00
|
|
|
svn export --quiet ${EOL} ${EXPORT_URL} ${TARGET}
|
2005-11-12 10:06:54 +03:00
|
|
|
|
2006-04-06 21:22:39 +04:00
|
|
|
### Various shifting, cleanup.
|
2005-11-12 10:06:54 +03:00
|
|
|
|
2006-04-06 21:22:39 +04:00
|
|
|
# Remove some not useful directories
|
Do a documentation reorganization I've been dying to do for some time
now. Get stuff that's aimed at regular developers off our website,
get the website out of our release tarballs, while letting the docs/
that ViewVC admins need remain in the tarballs.
* docs/
New directory.
* docs/url-reference.html,
* docs/template-authoring-guide.html
Moved these documents, which hardly need to live on our public website, here ...
* viewvc.org/url-reference.html,
* viewvc.org/template-authoring-guide.html
... from here.
* docs/upgrading-howto.html
Move (and renamed, and de-website-ized) this...
* viewvc.org/upgrading.html
... from here.
* notes/
New directory for developer notes.
* notes/releases.txt
New, cored out of the contributing.html file, and greatly updated to
track the reality of our new Subversion-land release process.
* notes/TODO
Move here ...
* TODO
... from here.
* viewvc.org/who.html,
* viewvc.org/license-1.html
Lose references to upgrading.html.
* viewvc.org/contributing.html
Lose references to upgrading.html, and move the release rolling
instructions out to notes/releases.txt.
* tools/make-release
Also delete viewvc.org/ and notes/ from the distribution.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1401 8cb11bc2-c004-0410-86c3-e597b4017df7
2006-07-27 00:19:22 +04:00
|
|
|
for JUNK in elemx \
|
Wow. Drop a "general code cleanup" kind of bomb on the codebase. All
of this is aimed at not paying the maintenance price of supporting
Python versions prior to 2.4 any longer, plus a little bit of just
getting dead code out of the way.
* lib/compat.py
Remove as unused.
* bin/cvsdbadmin,
* bin/loginfo-handler,
* bin/make-database,
* bin/svndbadmin,
* lib/accept.py,
* lib/blame.py,
* lib/cvsdb.py,
* lib/popen.py,
* lib/query.py,
* lib/sapi.py,
* lib/vcauth/forbidden/__init__.py
* lib/vcauth/forbiddenre/__init__.py,
* lib/vcauth/svnauthz/__init__.py,
* lib/vclib/__init__.py,
* lib/vclib/ccvs/blame.py,
* lib/win32popen.py,
* tests/timelog.py
Replace explicit import and use of the 'string' module with newer constructs.
* bin/standalone.py,
* lib/viewvc.py
No longer use 'compat' module. Replace explicit import and use of
the 'string' module with newer constructs.
* lib/dbi.py
Use calender.timegm() instead of compat.timegm().
* lib/vcauth/__init__.py
Lose unused module imports.
* lib/config.py,
Replace explicit import and use of the 'string' module with newer
constructs where possible. Lose old ConfigParser patch-up code for
Python 1.5.1.
* lib/vclib/ccvs/ccvs.py
Replace explicit import and use of the 'string' module with newer
constructs where possible. Import _path_join() from bincvs, and use
it instead of a bunch of copy-and-pasted string join() statements
throughout.
* lib/vclib/ccvs/__init__.py
(cvs_strptime): Moved here from the 'compat' module.
* lib/vclib/ccvs/bincvs.py
(): No longer use 'compat' module. Replace explicit import and use
of the 'string' module with newer constructs.
(_path_join): New, used now instead of a bunch of copy-and-pasted
string join() statements throughout.
* viewvc-install
Don't use the 'compat' module any more.
Also, so some rearranging of non-critical bits.
* misc/: New directory.
* misc/py2html.py: Moved from 'lib/py2html.py'.
* misc/PyFontify.py: Moved from 'lib/PyFontify.py'.
* misc/elemx/: Moved from 'elemx/'.
* misc/tparse/: Moved from 'tparse/'.
* tools/make-release
Omit 'misc' directory from releases, too.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2437 8cb11bc2-c004-0410-86c3-e597b4017df7
2010-09-03 20:49:52 +04:00
|
|
|
misc \
|
Do a documentation reorganization I've been dying to do for some time
now. Get stuff that's aimed at regular developers off our website,
get the website out of our release tarballs, while letting the docs/
that ViewVC admins need remain in the tarballs.
* docs/
New directory.
* docs/url-reference.html,
* docs/template-authoring-guide.html
Moved these documents, which hardly need to live on our public website, here ...
* viewvc.org/url-reference.html,
* viewvc.org/template-authoring-guide.html
... from here.
* docs/upgrading-howto.html
Move (and renamed, and de-website-ized) this...
* viewvc.org/upgrading.html
... from here.
* notes/
New directory for developer notes.
* notes/releases.txt
New, cored out of the contributing.html file, and greatly updated to
track the reality of our new Subversion-land release process.
* notes/TODO
Move here ...
* TODO
... from here.
* viewvc.org/who.html,
* viewvc.org/license-1.html
Lose references to upgrading.html.
* viewvc.org/contributing.html
Lose references to upgrading.html, and move the release rolling
instructions out to notes/releases.txt.
* tools/make-release
Also delete viewvc.org/ and notes/ from the distribution.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1401 8cb11bc2-c004-0410-86c3-e597b4017df7
2006-07-27 00:19:22 +04:00
|
|
|
notes \
|
|
|
|
tests \
|
|
|
|
tools \
|
|
|
|
tparse \
|
|
|
|
viewcvs.sourceforge.net \
|
|
|
|
viewvc.org \
|
|
|
|
www; do
|
2007-04-10 11:04:51 +04:00
|
|
|
if [ -d ${TARGET}/${JUNK} ]; then
|
|
|
|
echo " Removing ${TARGET}/${JUNK}..."
|
|
|
|
rm -r ${TARGET}/${JUNK}
|
2006-05-19 19:37:56 +04:00
|
|
|
fi
|
|
|
|
done
|
2005-11-12 10:06:54 +03:00
|
|
|
|
2006-04-06 21:22:39 +04:00
|
|
|
# Make sure permissions are reasonable:
|
2007-04-10 11:04:51 +04:00
|
|
|
echo " Normalizing permissions..."
|
2006-04-06 21:22:39 +04:00
|
|
|
find ${TARGET} -print | xargs chmod uoa+r
|
|
|
|
find ${TARGET} -type d -print | xargs chmod uoa+x
|
2001-11-28 00:18:39 +03:00
|
|
|
|
2006-04-06 21:22:39 +04:00
|
|
|
if test ${PLATFORM} = windows; then
|
|
|
|
# Create also a ZIP file for those poor souls :-) still using Windows:
|
2007-04-10 11:04:51 +04:00
|
|
|
echo " Creating ZIP archive..."
|
2006-04-06 21:22:39 +04:00
|
|
|
zip -qor9 ${TARGET}.zip ${TARGET}
|
|
|
|
else
|
|
|
|
# Cut the tarball:
|
2007-04-10 11:04:51 +04:00
|
|
|
echo " Creating tarball archive..."
|
2006-04-06 21:22:39 +04:00
|
|
|
tar cf - ${TARGET} | gzip -9 > ${TARGET}.tar.gz
|
|
|
|
fi
|
2000-05-09 15:00:50 +04:00
|
|
|
|
2006-04-06 21:22:39 +04:00
|
|
|
# remove target directory
|
|
|
|
rm -r ${TARGET}
|
|
|
|
done
|
2007-04-10 11:04:51 +04:00
|
|
|
echo "Done."
|