File tree 2 files changed +28
-1
lines changed
2 files changed +28
-1
lines changed Original file line number Diff line number Diff line change
1
+ # Build artifacts in main and subdirs
2
+ .build
Original file line number Diff line number Diff line change 1
1
FILTERS =$(wildcard $(shell find * -type d | grep -v '[/\\]') )
2
+ FILTER_FILES =$(shell find * -name "* .lua" -type f)
2
3
LUA_FILTERS_TEST_IMAGE = pandoc/lua-filters-test
3
4
4
- .PHONY : test docker-test docker-test-image
5
+ .PHONY : test show-args docker-test docker-test-image archive
5
6
6
7
test :
7
8
bash runtests.sh $(FILTERS )
8
9
10
+ archive : .build/lua-filters.tar.gz
11
+
12
+ show-vars :
13
+ @printf " FILTERS: %s\n" $(FILTERS )
14
+ @printf " FILTER_FILES: %s\n" $(FILTER_FILES )
15
+
9
16
docker-test :
10
17
docker run --rm --volume " $( PWD) :/data" $(LUA_FILTERS_TEST_IMAGE ) \
11
18
make test
12
19
13
20
docker-test-image : .tools/Dockerfile
14
21
docker build --tag $(LUA_FILTERS_TEST_IMAGE ) --file $< .
22
+
23
+ # Build a single collection of Lua filters
24
+ .PHONY : collection
25
+ collection : .build/lua-filters
26
+
27
+ .build/lua-filters : $(FILTER_FILES )
28
+ mkdir -p .build/lua-filters
29
+ cp -a $(FILTER_FILES ) .build/lua-filters
30
+ cp -a LICENSE .build/lua-filters
31
+ @printf " Filters collected in '%s'\n" " $@ "
32
+
33
+ .build/lua-filters.tar.gz : .build/lua-filters
34
+ tar -czf $@ -C .build lua-filters
35
+ @printf " Archive written to '%s'\n" " $@ "
36
+
37
+ clean :
38
+ rm -rf .build
39
+ $(foreach f,$(FILTERS ) ,make -C $(f ) clean;)
You can’t perform that action at this time.
0 commit comments