-
Notifications
You must be signed in to change notification settings - Fork 25
/
Makefile
79 lines (54 loc) · 2.16 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
78
79
.PHONY: dev docker-up docker-up-db docker-run docker-stop ssh stage-import
db ?= sidewalk
dir ?= ./
args ?=
html-ignore ?= **/bootstrap/**
dev: | docker-up-db docker-run
eslint: | lint-eslint
htmlhint: | lint-htmlhint
stylelint: | lint-stylelint
eslint-fix: | lint-fix-eslint
stylelint-fix: | lint-fix-stylelint
lint:
@make lint-eslint; make lint-htmlhint; make lint-stylelint
lint-fix:
@make lint-fix-eslint; make lint-fix-stylelint
docker-up:
@docker-compose up -d
docker-up-db:
@docker-compose up -d db
docker-stop:
@docker-compose stop
@docker-compose rm -f
docker-run:
@docker-compose run --rm --service-ports --name projectsidewalk-web web /bin/bash
ssh:
@docker exec -it projectsidewalk-$${target} /bin/bash
import-users:
@docker exec -it projectsidewalk-db sh -c "/opt/scripts/import-users.sh"
import-dump:
@docker exec -it projectsidewalk-db sh -c "/opt/scripts/import-dump.sh $(db)"
create-new-schema:
@docker exec -it projectsidewalk-db sh -c "/opt/scripts/create-new-schema.sh $(name)"
fill-new-schema:
@docker exec -it projectsidewalk-db sh -c "/opt/scripts/fill-new-schema.sh"
hide-streets-without-imagery:
@docker exec -it projectsidewalk-db sh -c "/opt/scripts/hide-streets-without-imagery.sh"
reveal-or-hide-neighborhoods:
@docker exec -it projectsidewalk-db sh -c "/opt/scripts/reveal-or-hide-neighborhoods.sh"
lint-htmlhint:
@echo "Running HTMLHint...";
@if [ "$(dir)" = "./" ]; then \
./node_modules/htmlhint/bin/htmlhint $(args) --ignore $(html-ignore) ./app/views; \
else \
./node_modules/htmlhint/bin/htmlhint $(args) --ignore $(html-ignore) $(dir); \
fi
@echo "Finished Running HTMLHint";
lint-eslint:
@echo "Running eslint..."; ./node_modules/eslint/bin/eslint.js $(args) $(dir); echo "Finished Running eslint"
lint-stylelint:
@echo "Running stylelint..."; ./node_modules/stylelint/bin/stylelint.js $(args) $(dir); echo "Finished Running stylelint"
lint-fix-eslint:
@echo "Running eslint..."; ./node_modules/eslint/bin/eslint.js --fix $(args) $(dir); echo "Finished Running eslint"
lint-fix-stylelint:
@echo "Running stylelint..."; ./node_modules/stylelint/bin/stylelint.js --fix $(args) $(dir); echo "Finished Running stylelint"