-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathHacefile.yml
91 lines (82 loc) · 1.72 KB
/
Hacefile.yml
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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
variables:
FLAGS: "-d --error-trace -Dpreview_mt"
NAME: "nicolino"
tasks:
build:
default: true
dependencies:
- src
- shard.lock
- shard.yml
- Hacefile.yml
outputs:
- bin/{{NAME}}
commands: |
shards build {{FLAGS}}
get-deps:
dependencies:
- shard.yml
outputs:
- shard.lock
commands: |
shards install
build-release:
phony: true
always_run: true
commands: |
rm bin/nicolino
hace build FLAGS="--release -Dpreview_mt"
install:
phony: true
always_run: true
dependencies:
- bin/{{name}}
commands: |
rm ${HOME}/.local/bin/{{NAME}}
cp bin/{{name}} ${HOME}/.local/bin/{{NAME}}
lint:
dependencies:
- src
- shard.lock
- shard.yml
commands: |
crystal tool format src/*.cr
bin/ameba --fix
always_run: true
phony: true
deploy:
dependencies:
- bin/nicolino
- src
- shard.lock
- shard.yml
- content
commands: |
rm -rf content/bench/
rm -rf output/
bin/nicolino build -B
rsync -rzav --delete output/* ralsina@rocky:/data/stacks/web/websites/nicolino.ralsina.me/
outputs:
- output/sitemap.xml
pre-commit:
default: true
outputs:
- .git/hooks/commit-msgstatic
- .git/hooks/pre-commit
dependencies:
- .pre-commit-config.yaml
commands: |
pre-commit install --hook-type commit-msg
pre-commit install
clean:
phony: true
always_run: true
commands: |
rm -rf shard.lock bin lib
static:
outputs:
- bin/{{NAME}}-static-linux-amd64
# - bin/{{NAME}}-static-linux-arm64
commands: |
hace clean
./build_static.sh