diff options
author | Ralph Amissah <ralph.amissah@gmail.com> | 2023-06-20 15:19:06 -0400 |
---|---|---|
committer | Ralph Amissah <ralph.amissah@gmail.com> | 2023-06-20 15:19:06 -0400 |
commit | 4e6b009500c1900e9e83dfb25b174cb08337edc8 (patch) | |
tree | 66cb683a94adbf8eee7de981181865825629dbe8 /makefile | |
parent | flake.nix offer build bypass of ldc overlay (diff) |
makefile add gitZip, git archive
Diffstat (limited to 'makefile')
-rw-r--r-- | makefile | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -5,6 +5,8 @@ include .envrc-local #SpineSearchAction := 'https://sisudoc.org/spine_search' #SpineCGIform := 'spine_search' #SpineSQLdb := 'spine.search.db' +PROG_VER_GIT :=$(shell echo `git describe --long --tags | sed -e "s/^[ a-z_-]\+\([0-9.]\+\)/\1/;s/\([^-]*-g\)/r\1/;s/-/./g"`) +PROG_VER_DECLARED :=$(shell echo `cat ./views/version.txt | grep --color=never "enum" | sed 's/.\+(\([0-9]\+\),[ \t]\+\([0-9]\+\),[ \t]\+\([0-9]\+\)[ \t]*).\+/\1.\2.\3/g'`) default: flake-check @@ -88,3 +90,11 @@ set_depends: get_depends cp-cgi: sudo cp -vi /var/www/cgi/cgi-bin/spine_search /var/www/cgi/cgi-bin/spine_search_old && \ sudo cp -vi result/share/cgi-bin/spine_search /var/www/cgi/cgi-bin/spine_search + +# git archive +gitZip: + if [ ! -d "./tarballGitHEAD" ]; then \ + mkdir ./tarballGitHEAD; \ + fi; \ + git archive -v --format=tar --prefix=`echo spine-search-$(PROG_VER_DECLARED)-tag-$(PROG_VER_GIT)`/ HEAD | gzip > ./tarballGitHEAD/spine-search-$(PROG_VER_DECLARED)-tag-$(PROG_VER_GIT).tar.gz && \ + echo "to unzip: tar -xzf spine-search-$(PROG_VER_DECLARED)-tag-$(PROG_VER_GIT).tar.gz" |