aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorNicolas LÅ“uillet <nicolas@loeuillet.org>2016-10-09 20:21:02 +0200
committerNicolas LÅ“uillet <nicolas@loeuillet.org>2016-10-09 20:21:02 +0200
commitd8507addbb2e222462f814718cb61d3eaf2c65e1 (patch)
tree7ebaba558d20a97ebb4b043e6fe66756aa857a54
parent5112b3556b5a85c791cac6ec89c19939e0677904 (diff)
downloadwallabag-d8507addbb2e222462f814718cb61d3eaf2c65e1.tar.gz
wallabag-d8507addbb2e222462f814718cb61d3eaf2c65e1.tar.zst
wallabag-d8507addbb2e222462f814718cb61d3eaf2c65e1.zip
First draft for Makefile
-rwxr-xr-xMakefile47
-rwxr-xr-xinstall.sh6
2 files changed, 47 insertions, 6 deletions
diff --git a/Makefile b/Makefile
new file mode 100755
index 00000000..0abd5c5d
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,47 @@
1TMP_FOLDER=/tmp
2RELEASE_FOLDER=wllbg-release
3
4SSH_USER=framasoft_bag
5SSH_HOST=78.46.248.87
6SSH_PATH=/var/www/framabag.org/web
7
8help:
9 @echo 'Makefile for wallabag '
10 @echo ' '
11 @echo 'Usage: '
12 @echo ' make install install latest stable wallabag version '
13 @echo ' make update update to the latest stable wallabag version'
14 @echo ' make build run grunt '
15 @echo ' make test execute wallabag testsuite '
16 @echo ' make release produce a wallabag release '
17 @echo ' make travis make things for travis '
18 @echo ' '
19
20install:
21 TAG=$(git describe --tags $(git rev-list --tags --max-count=1))
22 @git checkout $(TAG)
23 SYMFONY_ENV=prod composer install --no-dev -o --prefer-dist
24 php bin/console wallabag:install --env=prod
25
26update:
27
28build:
29 grunt
30
31test:
32 ant prepare && phpunit -v
33
34release:
35 version=$(VERSION)
36 rm -rf $(TMP_FOLDER)/$(RELEASE_FOLDER)
37 mkdir $(TMP_FOLDER)/$(RELEASE_FOLDER)
38 @git clone git@github.com:wallabag/wallabag.git -b $(VERSION) $(TMP_FOLDER)/$(RELEASE_FOLDER)/$(VERSION)
39 cd $(TMP_FOLDER)/$(RELEASE_FOLDER)/$(VERSION) && SYMFONY_ENV=prod composer up -n --no-dev
40 cd $(TMP_FOLDER)/$(RELEASE_FOLDER)/$(VERSION) && php bin/console wallabag:install --env=prod
41 cd $(TMP_FOLDER)/$(RELEASE_FOLDER) && tar czf wallabag-$(VERSION).tar.gz --exclude="var/cache/*" --exclude="var/logs/*" --exclude="var/sessions/*" --exclude=".git" $(VERSION)
42 @echo "MD5 checksum of the package for wallabag $(VERSION)"
43 @md5 $(TMP_FOLDER)/$(RELEASE_FOLDER)/wallabag-$(VERSION).tar.gz
44 scp $(TMP_FOLDER)/$(RELEASE_FOLDER)/wallabag-$(VERSION).tar.gz $(SSH_USER)@$(SSH_HOST):$(SSH_PATH)
45 rm -rf $(TMP_FOLDER)/$(RELEASE_FOLDER)
46
47travis:
diff --git a/install.sh b/install.sh
deleted file mode 100755
index 901b3446..00000000
--- a/install.sh
+++ /dev/null
@@ -1,6 +0,0 @@
1#! /usr/bin/env bash
2
3TAG=$(git describe --tags $(git rev-list --tags --max-count=1))
4git checkout $TAG
5SYMFONY_ENV=prod composer install --no-dev -o --prefer-dist
6php bin/console wallabag:install --env=prod