-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
78 lines (61 loc) · 1.85 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
all:
make release
build:
git log -n24 --date='format:%F %H:%M' --pretty='format:<tr><td>%ad</td><td><a href="https://git.xw3.org/xw3/xw3/commit/%H" class="commit" target="_blank">%s</a></td></tr>' > gitlog.html
cd cgi && git log -n24 --date='format:%F %H:%M' --pretty='format:<tr><td>%ad</td><td><a href="https://git.xw3.org/xw3/cgi/commit/%H" class="commit" target="_blank">%s</a></td></tr>' > ../gitlog_cgi.html && cd ..
cd lib && git log -n24 --date='format:%F %H:%M' --pretty='format:<tr><td>%ad</td><td><a href="https://git.xw3.org/xw3/lib/commit/%H" class="commit" target="_blank">%s</a></td></tr>' > ../gitlog_lib.html && cd ..
bundle exec jekyll b --incremental
clean:
rm -rf _site/*
rm -f gitlog.html
freshrelease:
make clean
make build
make minify
make sync
freshreleaseraw:
make clean
make build
make sync
freshrun:
make clean
make build
make minify
make run
local:
make clean
make build
make minify
mkdir -p ./_site/.well-known/
localraw:
make clean
make build
mkdir -p ./_site/.well-known/
localrelease:
make local
make minify
minify:
find ./_site -name "*.html" -exec minify --html-keep-document-tags --html-keep-end-tags -o {} {} \;
find ./_site -name "*.css" -exec minify --css-precision 0 -o {} {} \;
find ./_site -name "*.xml" -exec minify -o {} {} \;
release:
make build
make minify
make sync
releaseraw:
make build
make sync
run:
bundle exec jekyll s --incremental --drafts
runclean:
make clean
bundle exec jekyll s --incremental --drafts
runcleanreload:
make clean
bundle exec jekyll s --incremental --drafts --livereload
runreload:
bundle exec jekyll s --incremental --drafts --livereload
sync:
rsync -avr --delete --delete-excluded ./_site/ xw3.org:/var/www/xw3.org/www/_site/
ssh a.xw3.org 'cd /var/www/xw3.org/www/lib/ && git pull'
ssh a.xw3.org 'cd /var/www/xw3.org/www/_site/cgi/bin/ && gcc index.c -o index'