]> git.immae.eu Git - github/wallabag/wallabag.git/blame - scripts/update.sh
Added require.sh to check if composer is installed
[github/wallabag/wallabag.git] / scripts / update.sh
CommitLineData
4e7863c6 1#! /usr/bin/env bash
7c122534
NL
2# You can execute this file to update wallabag
3# eg: `sh update.sh prod`
4e7863c6 4
9998c725
NL
5DIR="${BASH_SOURCE%/*}"
6if [[ ! -d "$DIR" ]]; then DIR="$PWD"; fi
7. "$DIR/require.sh"
8
4e7863c6
NL
9ENV=$1
10TAG=$(git describe --tags $(git rev-list --tags --max-count=1))
11
12rm -rf var/cache/*
13git fetch origin
14git fetch --tags
84e3c36e 15git checkout $TAG --force
4e7863c6
NL
16SYMFONY_ENV=$ENV composer install --no-dev -o --prefer-dist
17php bin/console cache:clear --env=$ENV