Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 53 lines (40 sloc) 1.198 kB
ad40ef0 @sit Basic Makefile and infrastructure to support dist tarballs.
sit authored
1 #
2 # Makefile for todo.txt
3 #
4
5 # Dynamically detect/generate version file as necessary
6 # This file will define a variable called VERSION.
7 .PHONY: .FORCE-VERSION-FILE
8 VERSION-FILE: .FORCE-VERSION-FILE
9 @./GEN-VERSION-FILE
10 -include VERSION-FILE
11
12 # Maybe this will include the version in it.
13 todo.sh: VERSION-FILE
14
15 # For packaging
2b0921f @inkarkat Add todo_completion to todo.txt distribution.
inkarkat authored
16 DISTFILES := todo.cfg todo_completion
ad40ef0 @sit Basic Makefile and infrastructure to support dist tarballs.
sit authored
17
7f954d7 Merged test and dist Makefile to master branch for easier dev
U-STARBUCK\gina authored
18 DISTNAME=todo.txt_cli-$(VERSION)
ad40ef0 @sit Basic Makefile and infrastructure to support dist tarballs.
sit authored
19 dist: $(DISTFILES) todo.sh
20 mkdir -p $(DISTNAME)
21 cp -f $(DISTFILES) $(DISTNAME)/
0b3d910 @sit todo.sh: Generate version info at dist time.
sit authored
22 sed -e 's/@DEV_VERSION@/'$(VERSION)'/' todo.sh > $(DISTNAME)/todo.sh
ad40ef0 @sit Basic Makefile and infrastructure to support dist tarballs.
sit authored
23 tar cf $(DISTNAME).tar $(DISTNAME)/
24 gzip -f -9 $(DISTNAME).tar
25 zip -9r $(DISTNAME).zip $(DISTNAME)/
26 rm -r $(DISTNAME)
27
28 .PHONY: clean
29 clean:
30 rm -f $(DISTNAME).tar.gz $(DISTNAME).zip
31
7f954d7 Merged test and dist Makefile to master branch for easier dev
U-STARBUCK\gina authored
32
b17cb11 @sit Initial test framework and first test.
sit authored
33 #
34 # Testing
35 #
36 TESTS = $(wildcard tests/t[0-9][0-9][0-9][0-9]-*.sh)
37 #TEST_OPTIONS=--verbose
38
39 test-pre-clean:
40 rm -rf tests/test-results "tests/trash directory"*
41
42 aggregate-results: $(TESTS)
43
44 $(TESTS): test-pre-clean
2df5f9f @inkarkat Fixed test environment for escaped test output.
inkarkat authored
45 -cd tests && ./$(notdir $@) $(TEST_OPTIONS)
b17cb11 @sit Initial test framework and first test.
sit authored
46
47 test: aggregate-results
48 tests/aggregate-results.sh tests/test-results/t*-*
49 rm -rf tests/test-results
50
51 # Force tests to get run every time
52 .PHONY: test test-pre-clean aggregate-results $(TESTS)
Something went wrong with that request. Please try again.