mirror of
https://github.com/Steffo99/config-fish.git
synced 2024-12-22 14:54:23 +00:00
Fix bug
This commit is contained in:
parent
d3d9b34917
commit
b2bc723b82
1 changed files with 6 additions and 8 deletions
|
@ -23,14 +23,6 @@ function update_peertube
|
||||||
set -g BACKUP_PATH "$BACKUP_DIR/sql-peertube_prod-"(date -Im)".bak"
|
set -g BACKUP_PATH "$BACKUP_DIR/sql-peertube_prod-"(date -Im)".bak"
|
||||||
echo_progress "Backup path will be: "
|
echo_progress "Backup path will be: "
|
||||||
echo_highlight "$BACKUP_PATH" \n
|
echo_highlight "$BACKUP_PATH" \n
|
||||||
|
|
||||||
if not test -d "$BACKUP_DIR"
|
|
||||||
echo_progress "Creating backup dir..." \n
|
|
||||||
mkdir -p backup
|
|
||||||
end
|
|
||||||
|
|
||||||
echo_progress "Dumping the database to the backup dir..."
|
|
||||||
pg_dump -F custom "peertube_prod" > "$BACKUP_PATH"
|
|
||||||
|
|
||||||
set -g LATEST (curl -s https://api.github.com/repos/chocobozzz/peertube/releases/latest | grep tag_name | cut -d '"' -f 4)
|
set -g LATEST (curl -s https://api.github.com/repos/chocobozzz/peertube/releases/latest | grep tag_name | cut -d '"' -f 4)
|
||||||
echo_progress "Updating to Peertube "
|
echo_progress "Updating to Peertube "
|
||||||
|
@ -38,6 +30,12 @@ function update_peertube
|
||||||
|
|
||||||
confirm
|
confirm
|
||||||
|
|
||||||
|
echo_progress "Creating backup dir..." \n
|
||||||
|
mkdir -p "$BACKUP_DIR"
|
||||||
|
|
||||||
|
echo_progress "Dumping the database to the backup dir..."
|
||||||
|
pg_dump -F custom "peertube_prod" > "$BACKUP_PATH"
|
||||||
|
|
||||||
set -g VERSIONS_DIR "$INSTALL_DIR/versions"
|
set -g VERSIONS_DIR "$INSTALL_DIR/versions"
|
||||||
echo_progress "Versions dir is: "
|
echo_progress "Versions dir is: "
|
||||||
echo_highlight "$VERSIONS_DIR" \n
|
echo_highlight "$VERSIONS_DIR" \n
|
||||||
|
|
Loading…
Reference in a new issue