From 8136d50f13e9b488cd9608b9860c62995e34b1ef Mon Sep 17 00:00:00 2001 From: Omar Roth Date: Sat, 9 Feb 2019 12:14:03 -0600 Subject: [PATCH] Updated Updating (markdown) --- Updating.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Updating.md b/Updating.md index 5db0e15..0088eb6 100644 --- a/Updating.md +++ b/Updating.md @@ -4,9 +4,11 @@ ```bash $ sudo -i -u invidious $ cd invidious +$ currentVersion=$(git rev-list --max-count=1 --abbrev-commit HEAD) $ git pull $ latestVersion=$(git describe --tags `git rev-list --tags --max-count=1`) $ git checkout $latestVersion +$ for i in `git rev-list --abbrev-commit $currentVersion..HEAD` ; do file=./config/migrate-scripts/migrate-db-$i.sh ; [ -f $file ] && $file ; done $ shards $ crystal build src/invidious.cr --release $ exit @@ -17,7 +19,9 @@ $ sudo systemctl restart invidious.service ```bash $ sudo -i -u invidious $ cd invidious +$ currentVersion=$(git rev-list --max-count=1 --abbrev-commit HEAD) $ git pull +$ for i in `git rev-list --abbrev-commit $currentVersion..HEAD` ; do file=./config/migrate-scripts/migrate-db-$i.sh ; [ -f $file ] && $file ; done $ shards $ crystal build src/invidious.cr --release $ exit