-
Notifications
You must be signed in to change notification settings - Fork 77
/
Makefile
51 lines (39 loc) · 1.23 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
# https://developers.google.com/apps-script/guides/clasp
# You can replace it with your own script ID so you can call `make apply` directly.
SCRIPT_ID?=replace-me
all: push
push:
@echo "Pushing Binance to Google Sheets to:"
@cat .clasp.json
@clasp push
setup:
@echo "Binance to Google Sheets is being configured for SCRIPT_ID: ${SCRIPT_ID}"
@echo '{"scriptId":"${SCRIPT_ID}"}' > .clasp.json
@echo "DONE:"
@cat .clasp.json
update:
@echo "Pulling from repo and pushing to configured SCRIPT_ID.."
@git pull
${MAKE} push
##
# Next ones are for internal development purposes only =]
##
versions:
@clasp versions
deploys:
@clasp deployments
demo:
@cd ../binance-to-google-sheets-copies && ${MAKE} demo
dev: push
@cd ../binance-to-google-sheets-copies && ${MAKE}
generate:
@rm -f BINANCE-ALL.gs
@find . -type f \( -iname "*.gs" ! -iname "config.gs" ! -iname "main.gs" ! -iname "tmp.gs" \) -exec cat > tmp.gs {} +
@cat config.gs > BINANCE-ALL.gs
@printf "\n\n/////////////////////////////////////\n\n" >> BINANCE-ALL.gs
@cat main.gs >> BINANCE-ALL.gs
@printf "\n\n/////////////////////////////////////\n\n" >> BINANCE-ALL.gs
@cat tmp.gs >> BINANCE-ALL.gs
@rm -f tmp.gs
@echo "BINANCE-ALL.gs generated!"
.PHONY: demo dev generate