aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2021-08-25 18:12:44 +0200
committerDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2021-08-25 18:16:11 +0200
commita78e06df2e2e54c82114fa07f8c6b3ced3f6acbe (patch)
tree39112d357290f1e5b487f0d26da2324508eeb4c0
parentc8d76c4b29e9f545d45a9f128657a85ebc5f9d08 (diff)
downloadetc_apache2-a78e06df2e2e54c82114fa07f8c6b3ced3f6acbe.zip
etc_apache2-a78e06df2e2e54c82114fa07f8c6b3ced3f6acbe.tar.gz
etc_apache2-a78e06df2e2e54c82114fa07f8c6b3ced3f6acbe.tar.bz2
Makefile: Add update target
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
-rw-r--r--Makefile12
1 files changed, 12 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 660f109..cd5467b 100644
--- a/Makefile
+++ b/Makefile
@@ -2,6 +2,10 @@
DESTDIR ?= /var/www/git.replicant.us
+# For make update
+REMOTE ?= origin
+BRANCH ?= master
+
all: help install-sources
help:
@@ -11,6 +15,7 @@ help:
@echo " directory for AGPLv3+ compliance"
@echo "make install-hooks: Deploys a git hook to automatically instal the"
@echo " source code on git checkout"
+ @echo "make update: Pull in last changes from upstream in the current git repository"
install-hooks: hooks/post-checkout
install $< -m 770 -t .git/hooks
@@ -31,3 +36,10 @@ apache2.tar:
apache2.tar.xz: apache2.tar
rm -f $@
xz -9e --verbose $<
+
+update:
+ git fetch $(REMOTE)
+ git verify-commit $(REMOTE)/$(BRANCH)
+ git rebase $(REMOTE)/$(BRANCH)
+ make install-sources
+ systemctl reload apache2