Creating symlink from absolute path

This commit is contained in:
Manuel 2018-11-26 21:09:16 +01:00
parent 6fdc59d957
commit abba83c99b

View file

@ -17,7 +17,7 @@ do
gzip -f "$FILENAME" gzip -f "$FILENAME"
echo "==> Creating symlink to latest backup: $(basename "$FILENAME".gz)" echo "==> Creating symlink to latest backup: $(basename "$FILENAME".gz)"
rm "$LATEST" 2> /dev/null rm "$LATEST" 2> /dev/null
cd backup && ln -s $(basename "$FILENAME".gz) $(basename "$LATEST") && cd .. cd /backup && ln -s $(basename "$FILENAME".gz) $(basename "$LATEST") && cd -
else else
rm -rf "$FILENAME" rm -rf "$FILENAME"
fi fi