summaryrefslogtreecommitdiffstats
path: root/Makefile
blob: f939081db6234f51768a11e8c460fa7a30ec51ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
.PHONY: ghci
ghci: shell.nix
	nix-shell --arg nixpkgs 'import <stockholm>' --command 'exec ghci -Wall'

shell.nix: $(wildcard *.cabal)
	cabal2nix --shell . > $@

.PHONY: clean
clean:
	@find * -type f \( -name \*.o -o -name \*.hi \) -exec rm -v \{\} \;

.PHONY: install
install:
	nix-env --arg target "$$(cabal2nix .)" -f install.nix -i

.PHONY: install-env
install-env:
	nix-env -f env.nix -i