#!/bin/sh set -x; GENDIR=~/dierundestundegen TMPGIT_POSTS=$GENDIR/drs-posts GIT_POSTS=https://kollegen.uber.space/gitea/dierundestunde/drs-posts.git # For the very first time: create dir if [ ! -d $TMPGIT_POSTS ] then mkdir -v $TMPGIT_POSTS fi # Check, if there is really the repro inside if [ ! -d $TMPGIT_POSTS/.git ] then # jetzt clonen wir das Repository in den temporären Ordner git clone $GIT_POSTS $TMPGIT_POSTS 2>&1 | tee -a $LOG else env -i git -C $TMPGIT_POSTS pull 2>&1 | tee -a $LOG fi