]>
git.immae.eu Git - github/Chocobozzz/PeerTube.git/blob - scripts/upgrade-peertube.sh
4 [ "$1" = "`echo -e "$1\n$2" | sort -V | head -n1`" ]
10 actualNodeVersion
=$(node --version | tr -d "v")
11 actualNpmVersion
=$(npm --version)
13 if verlte
$actualNodeVersion $nodeMinVersion; then
14 echo 'You need node >= 6'
18 if verlte
$actualNpmVersion $npmMinVersion; then
19 echo 'You need npm >= 3'
23 if ! which yarn
> /dev
/null
; then
28 if pgrep peertube
> /dev
/null
; then
29 echo 'PeerTube is running, please shut it off before upgrading'
33 git pull origin
$(git rev-parse --abbrev-ref HEAD) || exit -1
35 yarn
install --pure-lockfile
38 echo -e "\n\nUpgrade finished! You can restart PeerTube that may run the migration scripts."