From b4a485a1e494b067d78bed965f74b95a7ad22c15 Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Thu, 9 May 2024 20:29:41 +1000 Subject: [PATCH] Fix release directory name and version file location --- Makefile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index f2b397af..38484e63 100644 --- a/Makefile +++ b/Makefile @@ -30,8 +30,8 @@ tag-sanitize-undefined = .san_u LDFLAGS-static-yes = -static -pthread -version = $(shell cat .version 2>/dev/null || git describe --tags HEAD 2>/dev/null || echo unknown) -version != cat .version 2>/dev/null || git describe --tags HEAD 2>/dev/null || echo unknown +version = $(shell cat .version 2>/dev/null || git describe --tags HEAD 2>/dev/null | sed s/^v// || echo unknown) +version != cat .version 2>/dev/null || ( git describe --tags HEAD 2>/dev/null | sed s/^v// ) || echo unknown PREFIX = /usr/local DESTDIR = # root dir @@ -154,9 +154,9 @@ kakoune-$(version).tar: @if ! [ -d .git ]; then echo "make dist can only run from a git repo"; false; fi @if git status -s | grep -qEv '^\?\?'; then echo "working tree is not clean"; false; fi git archive --format=tar --prefix=$(@:.tar=)/ HEAD -o $@ - echo "$(version)" > src/.version - tar --transform "s,^,$(@:.tar=)/," -rf $@ src/.version - rm -f src/.version + echo "$(version)" > .version + tar --transform "s,^,$(@:.tar=)/," -rf $@ .version + rm -f .version distclean: clean rm -f src/kak src/kak$(suffix) src/.*.d src/*.o