-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
35 lines (24 loc) · 1 KB
/
Copy pathMakefile
File metadata and controls
35 lines (24 loc) · 1 KB
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
build: ## Build the library
@cabal build all
test: ## Run the test suite
@cabal test all --test-show-details=direct
lint: ## Run hlint
@hlint src test
format: ## Format the sources and the cabal file
@fourmolu --quiet --mode inplace src test
@cabal-fmt --inplace json-pointer.cabal
format-check: ## Check that the sources and the cabal file are formatted
@fourmolu --quiet --mode check src test
@cabal-fmt --check json-pointer.cabal
check: format-check lint test ## Run all the checks
clean: ## Remove the cabal build artifacts
@cabal clean
repl: ## Start a cabal REPL
@cabal repl lib:json-pointer
help:
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.* ?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
SHELL := /usr/bin/env bash
# Spelled out rather than $(MAKECMDGOALS), so that the prerequisites of `check`
# are phony too - `test` would otherwise be shadowed by the test directory.
.PHONY: build test lint format format-check check clean repl help
.DEFAULT_GOAL := help