Permalink
Browse files

Rework the VERSION mangling in the make dist rule

  • Loading branch information...
1 parent 66a168d commit 4bfaaa2bc10912d91aef9a1db2a838eeb3f88de6 @jonas committed May 10, 2012
Showing with 3 additions and 4 deletions.
  1. +3 −3 Makefile
  2. +0 −1 contrib/release.sh
View
@@ -132,10 +132,10 @@ strip: $(PROGS)
dist: configure tig.spec
@mkdir -p $(TARNAME) && \
- cp tig.spec configure config.h.in aclocal.m4 $(TARNAME) && \
- echo $(VERSION) > $(TARNAME)/VERSION
+ cp Makefile tig.spec configure config.h.in aclocal.m4 $(TARNAME) && \
+ sed -i "s/VERSION\s=\s[0-9]\+[.][0-9]\+/VERSION = $(VERSION)/" $(TARNAME)/Makefile
git archive --format=tar --prefix=$(TARNAME)/ HEAD | \
- tar --delete $(TARNAME)/VERSION > $(TARNAME).tar && \
+ tar --delete $(TARNAME)/Makefile > $(TARNAME).tar && \
tar rf $(TARNAME).tar `find $(TARNAME)/*` && \
gzip -f -9 $(TARNAME).tar && \
md5sum $(TARNAME).tar.gz > $(TARNAME).tar.gz.md5
View
@@ -33,7 +33,6 @@ if test -n "$VERSION"; then
git checkout master
# Update files which should reference the version.
- echo "$VERSION" > VERSION
sed -i "s/VERSION\s=\s[0-9]\+[.][0-9]\+/VERSION = $VERSION/" Makefile
perl -pi -e 's/^tig master.*/@@TITLE@@/ms' NEWS
perl -pi -e "s/^@@TITLE@@.*/$TITLE/" NEWS

0 comments on commit 4bfaaa2

Please sign in to comment.