git.lirion.de

Of git, get, and gud

aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile38
1 files changed, 38 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..28264ac
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,38 @@
+all:
+
+FJVER := 9.0.2
+
+dirs: dirs-amd64 dirs-arm-6 dirs-arm64
+dirs-amd64:
+ @install -dvm0755 fs/{,amd64,amd64/usr,amd64/usr/bin}
+dirs-arm-6:
+ @install -dvm0755 fs/{,arm-6,arm-6/usr,arm-6/usr/bin}
+dirs-arm64:
+ @install -dvm0755 fs/{,arm64,arm64/usr,arm64/usr/bin}
+
+download: dirs dl-amd64 dl-arm-6 dl-arm64
+
+dl-amd64:
+ @printf 'forgejo-${FJVER}-amd64:\n'
+ @( cd fs/amd64/usr/bin && curl -#RLO -C - https://codeberg.org/forgejo/forgejo/releases/download/v${FJVER}/forgejo-${FJVER}-linux-amd64 )
+dl-arm-6:
+ @printf 'forgejo-${FJVER}-arm-6:\n'
+ @( cd fs/arm-6/usr/bin && curl -#RLO -C - https://codeberg.org/forgejo/forgejo/releases/download/v${FJVER}/forgejo-${FJVER}-linux-arm-6 )
+dl-arm64:
+ @printf 'forgejo-${FJVER}-arm64:\n'
+ @( cd fs/arm64/usr/bin && curl -#RLO -C - https://codeberg.org/forgejo/forgejo/releases/download/v${FJVER}/forgejo-${FJVER}-linux-arm64 )
+
+clean:
+ @printf 'Not clearing out the downloads, for that, use the target \033[1mclean-downloads\033[0m.\n'
+ @rm -rv ./nfpm/build/
+
+clean-downloads:
+ @rm -rv ./fs/*
+
+nfpm: nfpm-Makefile nfpm-descend
+
+nfpm-Makefile:
+ @sed -i 's/FJVER :=.*/FJVER := $"${FJVER}$"/' ./nfpm/Makefile
+
+nfpm-descend:
+ $(MAKE) -C ./nfpm