]> gitweb.fluxo.info Git - simplepkg.git/commitdiff
adding mkbuild --status
authorrhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58>
Mon, 19 Jan 2009 16:13:58 +0000 (16:13 +0000)
committerrhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58>
Mon, 19 Jan 2009 16:13:58 +0000 (16:13 +0000)
git-svn-id: svn+slack://slack.fluxo.info/var/svn/simplepkg@756 04377dda-e619-0410-9926-eae83683ac58

trunk/doc/CHANGELOG
trunk/src/createpkg
trunk/src/mkbuild

index 4c5b141b2f6d3d485fa005619c684e9e8d60f4f3..21f945e5ef8aeec46993a66a5f3ef015eb3f2c5a 100644 (file)
@@ -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
index 0a67648ef29d237d6633e3caf906188c8b91bf74..b3b3f973af28d912be93b46de1b800fc4fff8014 100644 (file)
@@ -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`"
index 00d6ac2f763b3bf31616a0b34de7b8f3b0f99209..d185ee0c9250d7a3067c278db41ba00e844bb2ac 100755 (executable)
@@ -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
     ;;