aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorJohn MacFarlane <[email protected]>2022-09-27 12:52:07 -0700
committerJohn MacFarlane <[email protected]>2022-09-27 12:52:27 -0700
commit301f9058397e8a8e255cd1ca390bc0f9e97a08f7 (patch)
treec245d95b3a620defdd8696b8dd16791bc713fa41 /Makefile
parent78c0016526ad0a4840162f09de7eded4a423f74e (diff)
Makefile: add transitive-deps target.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile19
1 files changed, 10 insertions, 9 deletions
diff --git a/Makefile b/Makefile
index bde2baef1..94e8621e4 100644
--- a/Makefile
+++ b/Makefile
@@ -68,14 +68,11 @@ reformat: ## reformat with stylish-haskell
for f in $(SOURCEFILES); do echo $$f; stylish-haskell -i $$f ; done
.PHONY: reformat
-lint: hlint fix_spacing ## run linters
-.PHONY: lint
-
-hlint: ## run hlint
+lint: ## run hlint
for f in $(SOURCEFILES); do echo $$f; hlint --refactor --refactor-options='-s -o -' $$f; done
-.PHONY: hlint
+.PHONY: lint
-fix_spacing: ## Fix trailing newlines and spaces
+fix_spacing: ## fix trailing newlines and spaces
for f in $(SOURCEFILES); do printf '%s\n' "`cat $$f`" | sed -e 's/ *$$//' > $$f.tmp; mv $$f.tmp $$f; done
.PHONY: fix_spacing
@@ -83,7 +80,7 @@ changes_github: ## copy this release's changes in gfm
pandoc --lua-filter tools/extract-changes.lua changelog.md -t gfm --wrap=none --template tools/changes_template.html | sed -e 's/\\#/#/g' | pbcopy
.PHONY: changes_github
-man: man/pandoc.1 man/pandoc-server.1 man/pandoc-lua.1
+man: man/pandoc.1 man/pandoc-server.1 man/pandoc-lua.1 ## build man pages
.PHONY: man
coverage: ## code coverage information
@@ -95,6 +92,10 @@ coverage: ## code coverage information
open coverage/hpc_index.html
.PHONY: coverage
+transitive-deps: ## print transitive dependencies
+ cabal-plan topo | sort | sed -e 's/-[0-9]\..*//'
+.PHONY: transitive-deps
+
debpkg: ## create linux package
docker run -v `pwd`:/mnt \
-v `pwd`/linux/artifacts:/artifacts \
@@ -127,7 +128,7 @@ README.md: README.template MANUAL.txt tools/update-readme.lua
pandoc --lua-filter tools/update-readme.lua \
--reference-location=section -t gfm $< -o $@
-doc/lua-filters.md: tools/update-lua-module-docs.lua
+doc/lua-filters.md: tools/update-lua-module-docs.lua ## update lua-filters.md module docs
cabal run pandoc -- --standalone \
--reference-links \
--lua-filter=$< \
@@ -167,7 +168,7 @@ sdist-files.txt: .FORCE
git-files.txt: .FORCE
git ls-tree -r --name-only HEAD | grep '^\(test\|data\)\/' | sort > $@
-help: ## Display this help
+help: ## display this help
@grep -E '^[ a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "%-30s %s\n", $$1, $$2}'
.PHONY: help