-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
85 lines (70 loc) · 3.3 KB
/
Makefile
File metadata and controls
85 lines (70 loc) · 3.3 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
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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
.PHONY: help docs docs-serve docs-clean test format check-format clean deps deps-docs deps-scripts benchmark benchmark-compare
# Colors for terminal output
ifdef NO_COLOR
GREEN :=
YELLOW :=
WHITE :=
RESET :=
else
GREEN := $(shell tput -Txterm setaf 2)
YELLOW := $(shell tput -Txterm setaf 3)
WHITE := $(shell tput -Txterm setaf 7)
RESET := $(shell tput -Txterm sgr0)
endif
# Default target
.DEFAULT_GOAL := help
## Show help for each of the Makefile targets
help:
@echo ''
@echo 'PLACEHOLDERNAME_CHANGE_MAKEFILE_LINE_22.jl Makefile ${YELLOW}targets${RESET}:'
@echo ''
@echo '${GREEN}Documentation commands:${RESET}'
@echo ' ${YELLOW}docs${RESET} Build the documentation'
@echo ' ${YELLOW}docs-serve${RESET} Serve documentation locally for preview in browser'
@echo ' ${YELLOW}docs-clean${RESET} Clean the documentation build directory'
@echo ''
@echo '${GREEN}Development commands:${RESET}'
@echo ' ${YELLOW}deps${RESET} Install project dependencies'
@echo ' ${YELLOW}deps-docs${RESET} Install documentation dependencies'
@echo ' ${YELLOW}deps-scripts${RESET} Install script dependencies'
@echo ' ${YELLOW}test${RESET} Run project tests'
@echo ' ${YELLOW}format${RESET} Format Julia code'
@echo ' ${YELLOW}check-format${RESET} Check Julia code formatting (does not modify files)'
@echo ' ${YELLOW}clean${RESET} Clean all generated files'
@echo ''
@echo '${GREEN}Benchmark commands:${RESET}'
@echo ' ${YELLOW}benchmark${RESET} Run project benchmarks'
@echo ' ${YELLOW}benchmark-compare${RESET} Run project benchmarks with comparison against specified branch'
@echo ''
@echo '${GREEN}Help:${RESET}'
@echo ' ${YELLOW}help${RESET} Show this help message'
@echo ''
@echo '${GREEN}Environment variables:${RESET}'
@echo ' ${YELLOW}NO_COLOR${RESET} Set this variable to any value to disable colored output'
@echo ''
## Documentation commands:
docs: deps-docs ## Build the documentation
julia --project=docs/ docs/make.jl
docs-serve: deps-docs ## Serve documentation locally for preview in browser
julia --project=docs/ -e 'using LiveServer; LiveServer.servedocs(launch_browser=true, port=5678)'
docs-clean: ## Clean the documentation build directory
rm -rf docs/build
## Development commands:
deps: ## Install project dependencies
julia --project -e 'using Pkg; Pkg.instantiate()'
deps-docs: ## Install documentation dependencies
julia --project=docs/ -e 'using Pkg; Pkg.develop(path="."); Pkg.instantiate()'
deps-scripts: ## Install script dependencies
julia --project=scripts/ -e 'using Pkg; Pkg.instantiate()'
test: deps ## Run project tests
julia --project -e 'using Pkg; Pkg.test()'
format: deps-scripts ## Format Julia code
julia --project=scripts/ scripts/formatter.jl --overwrite
check-format: deps-scripts ## Check Julia code formatting (does not modify files)
julia --project=scripts/ scripts/formatter.jl
benchmark: deps-scripts ## Run project benchmarks
julia --project=scripts/ scripts/bench.jl
benchmark-compare: deps-scripts ## Run project benchmarks with comparison against specified branch
julia --project=scripts/ scripts/bench.jl --compare-branch $(branch)
clean: docs-clean ## Clean all generated files
rm -rf .julia/compiled