-
Notifications
You must be signed in to change notification settings - Fork 28
/
Makefile
85 lines (67 loc) · 2.57 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
80
81
82
83
84
85
dev:
pkill -f http-server &
echo "Make sure to install http-server with npm i -g http-server"
elm-make Main.elm --output=example/elm.js --debug
(http-server ./example/ -p 8081 -c-1 &) && open "http://127.0.0.1:8081"
release:
elm-make Main.elm --output=example/elm.js
mkdir -p docs/stable
cp -r example/ docs/stable/
compile:
elm-make Main.elm --yes --output compiled.js
sed 's/var Elm = {}/&; \
require(".\/elchemy_node.js").execute(_user$$project$$Elchemy_Compiler$$tree, _user$$project$$Elchemy_Compiler$$fullTree, _user$$project$$Elchemy_Compiler$$treeAndCommons)/' compiled.js > elchemy.js
rm compiled.js
compile-watch:
find . -name "*.elm" | grep -v "elm-stuff" | grep -v .# | entr make compile
test:
./node_modules/.bin/elm-test
test-all:
make test
make test-std
make compile-elixir # Change to compile-elixir-and-test when let..in fixed completely
make test-project
test-project:
rm -rf test_project
mix new test_project
cd test_project ; \
(yes | ../elchemy init) ;\
../elchemy compile elm lib ;\
cp -r ../elchemy-core/lib lib/elm-deps ;\
cp -r ../elchemy-core/elm lib/elm-deps-elixir-files ;\
mix test
test-std:
cd elchemy-core/ && mix test
compile-std:
cd elchemy-core && rm -rf .elchemy
make compile-std-incremental
compile-std-incremental:
make compile
cd elchemy-core && ../elchemy compile elm lib
compile-std-watch:
find elchemy-core -name "*.elm" | grep -v ".#" | grep -v "elm-stuff" | entr make compile-std
compile-std-tests-watch:
find elchemy-core \( -name "*.elm" -or -name '*.ex*' \) | grep -v "elchemy.ex" | grep -v ".#" | grep -v "elm-stuff" | entr bash -c "make compile && make compile-std && make test-std"
compile-incremental-std-tests-watch:
find elchemy-core \( -name "*.elm" -or -name '*.ex*' \) | grep -v "elchemy.ex" | grep -v ".#" | grep -v "elm-stuff" | entr bash -c "make compile && make compile-std-incremental && make test-std"
tests-watch:
find . -name "*.elm" | grep -v ".#" | grep -v "elm-stuff" | entr ./node_modules/.bin/elm-test
install-sysconf:
git clone "https://github.com/obmarg/libsysconfcpus.git"
cd libsysconfcpus && ./configure && make && make install
cd .. && rm -rf libsysconfcpus
compile-elixir:
make compile
rm -rf elchemy_ex/elm-deps
rm -rf elchemy_ex/.elchemy
cd elchemy_ex && ../elchemy compile ../src lib
compile-elixir-and-run:
make compile-elixir
cd elchemy_ex && mix compile
compile-elixir-and-test:
make compile-elixir
cd elchemy_ex && mix test
build-docs:
cd ../elchemy-page && git checkout master && git pull && elm install && yarn && yarn build
rm -rf docs/*
cp -r ../elchemy-page/dist/* docs/