summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2013-12-26 23:20:09 -0200
committerSilvio Rhatto <rhatto@riseup.net>2013-12-26 23:20:09 -0200
commit7468b6ec0df6aa6c594640154eecb02b12cca5e5 (patch)
tree2d03a6110373d592f375a662066f16130e540cb3 /lib
parentb95155761a1789557ea1569491d149e3c90d295b (diff)
downloadkeyringer-7468b6ec0df6aa6c594640154eecb02b12cca5e5.tar.gz
keyringer-7468b6ec0df6aa6c594640154eecb02b12cca5e5.tar.bz2
Support for RELATIVE_FOLDER at git action
Diffstat (limited to 'lib')
-rwxr-xr-xlib/keyringer/actions/git10
1 files changed, 9 insertions, 1 deletions
diff --git a/lib/keyringer/actions/git b/lib/keyringer/actions/git
index 3c4f435..108ccea 100755
--- a/lib/keyringer/actions/git
+++ b/lib/keyringer/actions/git
@@ -12,5 +12,13 @@ CWD="`pwd`"
# Run git command
shift
-mkdir -p "$BASEDIR" && cd "$BASEDIR" && git $*
+
+# Set working folder
+if [ ! -z "$RELATIVE_PATH" ]; then
+ WORK="$KEYDIR/$RELATIVE_PATH"
+else
+ WORK="$BASEDIR"
+fi
+
+mkdir -p "$WORK" && cd "$WORK" && git $*
cd "$CWD"