forked from mlabs-haskell/hydra-auction
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
69 lines (53 loc) · 1.54 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
.PHONY:
check
hoogle
build
test
repl
format-check
format
lint-check
lint
clean
requires_nix_shell
check:
@nix flake check -Lv --impure --allow-import-from-derivation
hoogle: requires_nix_shell
@hoogle server --local --port=8070 > /dev/null &
build: requires_nix_shell
@cabal v2-build
test: requires_nix_shell
@cabal v2-test --test-show-details=direct
repl: requires_nix_shell
@nix develop -c cabal new-repl
format-check: requires_nix_shell
@sh format.sh check
format: requires_nix_shell
@sh format.sh
lint-check: requires_nix_shell
@sh lint.sh check
lint: requires_nix_shell
@sh lint.sh
build-docker:
nix build .#packages.x86_64-linux.delegateImage
docker load < result
start-docker:
./scripts/spin-up-new-devnet.sh
BUILD_PATH = "dist-newstyle"
NODE_STATE_PATH = "node-state"
clean:
@[ ! -e $(BUILD_PATH) ] || rm -rf $(BUILD_PATH)
@[ ! -e $(NODE_STATE_PATH) ] || rm -rf $(NODE_STATE_PATH)
# # Target to use as dependency to fail if not inside nix-shell.
requires_nix_shell:
@ [ "$(IN_NIX_SHELL)" ] || { \
echo "The $(MAKECMDGOALS) target must be run from inside a nix shell"; \
echo " run 'nix develop .' first"; \
false; \
}
demo-monitor:
cabal run hydra-auction -- -w demo -i 127.0.0.1 -d 1
demo-seller:
cabal run hydra-auction -- -a alice --cardano-node-socket /home/gregory/Programming/hydra-auction/devnet/node.socket --network-magic 42 -d 1 -i 127.0.0.1
demo-bidder:
cabal run hydra-auction -- -a bob --cardano-node-socket /home/gregory/Programming/hydra-auction/devnet/node.socket --network-magic 42 -d 2 -i 127.0.0.1