Added Makefile target for distribution tarballs.
authorAaron Marcher <me@drkhsh.at>
Sun, 13 Aug 2017 21:05:22 +0000 (23:05 +0200)
committerAaron Marcher <me@drkhsh.at>
Sun, 13 Aug 2017 21:05:22 +0000 (23:05 +0200)
Makefile

index dbe636e63e1dbbde182a023bf96db3dc017b9c43..9fea3d9c9e4dc3307cda69f409b70b93f54e6c34 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -15,6 +15,14 @@ config.h:
 clean:
        rm -f slstatus
 
+dist:
+       rm -rf "slstatus-$(VERSION)"
+       mkdir -p "slstatus-$(VERSION)"
+       cp -R arg.h config.def.h config.mk LICENSE Makefile README slstatus.1 \
+               slstatus.c slstatus.png "slstatus-$(VERSION)"
+       tar -cf - "slstatus-$(VERSION)" | gzip -c > "slstatus-$(VERSION).tar.gz"
+       rm -rf "slstatus-$(VERSION)"
+
 install: all
        mkdir -p "$(DESTDIR)$(PREFIX)/bin"
        cp -f slstatus "$(DESTDIR)$(PREFIX)/bin"