-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
38 lines (28 loc) · 1.03 KB
/
Copy pathMakefile
File metadata and controls
38 lines (28 loc) · 1.03 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
SHELL_FILES := $(shell git ls-files '*.bash' '*.sh' 'direnv/.config/direnv/direnvrc')
LUA_FILES := $(shell git ls-files '*.lua')
PYTHON_FILES := $(shell git ls-files '*.py')
.PHONY: help lint format format-sh format-lua format-python
help:
@echo "restore - Restore configuration files via \`stow\`"
@echo "install - Install platform-dependant packages and dependencies"
@echo "configure - Set system-wide configurations and settings"
@echo "lint - Run pre-commit checks across the repository"
@echo "format - Format shell, Lua, and Python files"
@echo "format-sh - Format shell files with shfmt"
@echo "format-lua - Format Lua files with stylua"
@echo "format-python - Format Python files with ruff"
lint:
pre-commit run --all-files
format: format-sh format-lua format-python
format-sh:
shfmt -w -i 4 $(SHELL_FILES)
format-lua:
stylua --config-path .stylua.toml $(LUA_FILES)
format-python:
uvx ruff format $(PYTHON_FILES)
restore:
./_restore.sh
install:
./_install.sh
configure:
./_configure.sh