diff options
author | rhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58> | 2009-01-19 16:13:58 +0000 |
---|---|---|
committer | rhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58> | 2009-01-19 16:13:58 +0000 |
commit | 9d18d292217f12e30467832f6ded72c70e67967b (patch) | |
tree | ed1b93db872b5c38cd94c763dfa62186157781f4 | |
parent | afb0901283052b06d75f04694f942139f424f177 (diff) | |
download | simplepkg-9d18d292217f12e30467832f6ded72c70e67967b.tar.gz simplepkg-9d18d292217f12e30467832f6ded72c70e67967b.tar.bz2 |
adding mkbuild --status
git-svn-id: svn+slack://slack.fluxo.info/var/svn/simplepkg@756 04377dda-e619-0410-9926-eae83683ac58
-rw-r--r-- | trunk/doc/CHANGELOG | 4 | ||||
-rw-r--r-- | trunk/src/createpkg | 2 | ||||
-rwxr-xr-x | trunk/src/mkbuild | 38 |
3 files changed, 39 insertions, 5 deletions
diff --git a/trunk/doc/CHANGELOG b/trunk/doc/CHANGELOG index 4c5b141..21f945e 100644 --- a/trunk/doc/CHANGELOG +++ b/trunk/doc/CHANGELOG @@ -28,7 +28,7 @@ simplepkg changelog - default configuration making createpkg repository integrated with simplaret - new repositories - mkbuild: - - added --edit command line option + - added --edit command line options, among others - code cleanup - all previous "commit" functions and command line options changed to "submit" as they don't really commit files into the svn repository @@ -44,7 +44,7 @@ simplepkg changelog - config() on postinstall_script now accepting .dist and .sample config file extensions - added git_source section - createpkg: - - new options --import, --status, --update and --commit to manage subversion repository + - new options --import, --status, --update and --commit to manage subversion repository, among others - subversion integration - minor changes - renamed config parameter CREATE_ARCH to CREATEPKG_ARCH diff --git a/trunk/src/createpkg b/trunk/src/createpkg index 0a67648..b3b3f97 100644 --- a/trunk/src/createpkg +++ b/trunk/src/createpkg @@ -309,6 +309,8 @@ function repository_update { function repository_status { + local cwd + if [ -d "$PACKAGES_DIR/.svn" ]; then echo "Status of $PACKAGES_DIR." cwd="`pwd`" diff --git a/trunk/src/mkbuild b/trunk/src/mkbuild index 00d6ac2..d185ee0 100755 --- a/trunk/src/mkbuild +++ b/trunk/src/mkbuild @@ -84,6 +84,8 @@ ${red}DESCRIPTION${normal} import SlackBuild repository in a svn tree ${red}-ia${normal}, ${red}-i${normal}, ${red}--import-all${normal}, ${red}--import${normal} import mkbuild and SlackBuild repositories in a svn tree + ${red}--status${normal} + print mkbuild and SlackBuild svn repositories status ${red}-h${normal}, ${red}--help${normal} this help mesage ${red}-n${normal}, ${red}--new${normal} ${green}<mkbuild_name>${normal} @@ -178,23 +180,28 @@ function set_parameters { break # we need to break otherwise commit log message is evalued ;; '-is'|'--import-slackbuilds') - # Commit SlackBuild file + # Import SlackBuilds ACTION="import_slackbuilds" MKBUILD_NAME="${2//.mkbuild}.mkbuild" break # we need to break otherwise specific arguments are evalued ;; '-im'|'--import-mkbuilds') - # import mkbuild file + # Import mkbuilds ACTION="import_mkbuilds" MKBUILD_NAME="${2//.mkbuild}.mkbuild" break # we need to break otherwise specific arguments are evalued ;; '-ia'|'-i'|'--import-all'|'--import') - # Commit SlackBuild and mkbuild file + # Import SlackBuilds and mkbuilds ACTION="import_all" MKBUILD_NAME="${2//.mkbuild}.mkbuild" break # we need to break otherwise specific arguments are evalued ;; + '--status') + # Repository status + ACTION="status" + break # we need to break otherwise specific arguments are evalued + ;; '-um'|'--update-manifest') ACTION="update_manifest" MKBUILD_NAME="${2//.mkbuild}.mkbuild" @@ -746,6 +753,28 @@ function import_slackbuilds { } +function repository_status { + + local cwd + + if [ -d "$MKBUILDS_DIR/.svn" ]; then + echo "Status of $MKBUILDS_DIR." + cwd="`pwd`" + cd $MKBUILDS_DIR && su_svn status + cd $cwd + fi + + if [ -d "$SLACKBUILDS_DIR/.svn" ]; then + cwd="`pwd`" + echo "Status of $SLACKBUILDS_DIR." + cd $SLACKBUILDS_DIR && su_svn status + cd $cwd + fi + + exit 0 + +} + # ---------------------------------------------------------------- # general functions # ---------------------------------------------------------------- @@ -1560,6 +1589,9 @@ if [ ! -z "$MKBUILD_NAME" ]; then 'search') search_mkbuild -i ;; + 'status') + repository_status + ;; 'edit') edit_mkbuild ;; |