diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2013-10-22 23:24:23 -0200 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2013-10-22 23:24:23 -0200 |
commit | 21e82b5c43fcdc21014b087e63dfc62b8f073b21 (patch) | |
tree | e059c83354f5898b9743da908007689e02106e74 /share | |
parent | b3c36890b5804a1ebc2a8cb4b6049b513abacf74 (diff) | |
download | hydra-21e82b5c43fcdc21014b087e63dfc62b8f073b21.tar.gz hydra-21e82b5c43fcdc21014b087e63dfc62b8f073b21.tar.bz2 |
Hydra sync: fix keyringer routines (3)
Diffstat (limited to 'share')
-rwxr-xr-x | share/hydra/sync | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/share/hydra/sync b/share/hydra/sync index 44f6f14..8ff57da 100755 --- a/share/hydra/sync +++ b/share/hydra/sync @@ -40,6 +40,21 @@ function hydra_sync { fi fi done + + # Update keyring. + if [ "$UPDATE_KEYRINGER" != "no" ]; then + if ! which keyringer &> /dev/null; then + echo "Please install keyringer for a full hydra experience." + elif [ ! -e "$HOME/.keyringer/$HYDRA" ]; then + echo "Initializing keyring for $HYDRA..." + keyringer $HYDRA init $HYDRA_FOLDER/$repository + fi + + echo "Syncing keyringer..." + keyringer $HYDRA git pull + fi + + UPDATE_KEYRINGER="no" } # Basic parameters. @@ -58,19 +73,6 @@ done # TODO: split between public and private repositories hydra_sync $REPOSITORIES -# Update keyring. -if [ "$UPDATE_KEYRINGER" != "no" ]; then - if ! which keyringer &> /dev/null; then - echo "Please install keyringer for a full hydra experience." - elif [ ! -e "$HOME/.keyringer/$HYDRA" ]; then - echo "Initializing keyring for $HYDRA..." - keyringer $HYDRA init $HYDRA_FOLDER/$repository - fi - - echo "Syncing keyringer..." - keyringer $HYDRA git pull -fi - # Update puppet configuration. if [ -z "$PUPPET" ]; then echo "Searching for a puppet repository at $BASEDIR..." |