diff options
author | Jon Clausen <jac@nordu.net> | 2018-12-12 08:40:40 +0100 |
---|---|---|
committer | Jon Clausen <jac@nordu.net> | 2018-12-12 08:40:40 +0100 |
commit | ddcaf2d7bce337057a3584e0b2d63f065cf19a3f (patch) | |
tree | 113178503a3f5d55940dbea506045dedd2b623b8 | |
parent | 7b512371bbf1e6e9a7c68969f2f0bd971ddde753 (diff) |
do a "git pull" (with error handling) before looking at stuff
-rwxr-xr-x | code/vlanscrape-wrapper | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/code/vlanscrape-wrapper b/code/vlanscrape-wrapper index bec76af..9bde36b 100755 --- a/code/vlanscrape-wrapper +++ b/code/vlanscrape-wrapper @@ -9,6 +9,13 @@ cd /home/vlanscrape/git/git.nordu.net/vlanscrape-data +PullMsg=$(git pull 2>&1) +if [ $? -ne 0 ] +then + echo "\"git pull\" failed: ${PullMsg}" + exit 1 +fi + TmpFile=$(mktemp) if [ -z "${TmpFile}" ] then |