-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
49 lines (36 loc) · 962 Bytes
/
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
# ---------------------------------------------------------------------------------
# Portal
# ---------------------------------------------------------------------------------
# -- Options
HOME=/Users/dmix
CONFIG_PATH=/usr/local/var/portal
DATA_PATH=/usr/local/lib/portal
ELVISH_DIR=~/.elvish/lib/portal
# -- Main
dev: initialize
@cargo watch -x 'run jump portal'
test:
@echo 'Testing'
initialize:
@mkdir -p $(ELVISH_DIR)
@mkdir -p $(DATA_PATH)
@touch $(DATA_PATH)/portal.log
@mkdir -p $(CONFIG_PATH)
@mkdir -p $(CONFIG_PATH)/db/
install: initialize
@cargo build
@cp -rf ./portal.toml $(CONFIG_PATH)/portal.toml
@cp -rf ./target/debug/portal /usr/local/bin/portal
reset:
@rm -rf $(DATA_PATH)/portal.log
@rm -rf $(DATA_PATH)/db/*
@touch $(DATA_PATH)/portal.log
# -- Helpers
tmux:
@tmuxp load .tmuxp.yaml
clean:
@cargo clean
@rm .DS_Store; rm **/*/.DS_Store
# -- Makefile
.PHONY := dev test install tmux clean
.DEFAULT_GOAL := dev