1 cabal = $(wildcard *.cabal)
2 package = $(notdir ./$(cabal:.cabal=))
3 version = $(shell sed -ne 's/^version: *\(.*\)/\1/p' $(cabal))
13 cabal test $(TESTFLAGS) --test-show-details always --test-options "$(TESTOPTIONS) --color always --size-cutoff 1000000 $${p:+-p $$p}"
14 %/accept: TESTOPTIONS+=--accept
17 %/cover: TESTFLAGS+=--enable-coverage
21 cabal v2-build lib:symantic-parser --enable-profiling --write-ghc-environment-files=always
22 cabal test $(TESTFLAGS) --enable-profiling -fprof-auto -fprof-auto-calls \
23 --test-show-details always --test-options "$(TESTOPTIONS) $${p:+-p $$p}" \
24 --ghc-options "-opti+RTS -opti-p -opti-L100 -opti-ls -opti-xc"
26 cabal repl --enable-tests symantic-parser-test
29 cabal haddock --haddock-css ocean --haddock-hyperlink-source
32 git tag --merged | grep -Fqx "$(package)-$(version)" || \
33 git tag -f -s -m "$(package) v$(version)" $(package)-$(version)
37 cabal haddock --haddock-for-hackage --enable-doc
40 cabal upload $(CABAL_UPLOAD_FLAGS) dist-newstyle/sdist/$(package)-$(version).tar.gz
41 cabal upload $(CABAL_UPLOAD_FLAGS) --documentation dist-newstyle/$(package)-$(version)-docs.tar.gz
42 %/publish: CABAL_UPLOAD_FLAGS+=--publish
45 publish: upload/publish
50 nix flake update --recreate-lock-file
52 nix -L develop --command cabal repl