-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
28 lines (27 loc) · 886 Bytes
/
Makefile
File metadata and controls
28 lines (27 loc) · 886 Bytes
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
# Define the directories and patterns to remove
CACHE_PATTERNS := **/ __pycache__ \
**/.pytest_cache \
**/.ipynb_checkpoints \
**/.DS_Store \
**/*.pyc \
**/*.pyo \
**/*.pyd \
**/.mypy_cache \
**/.sass-cache \
**/.eslintcache \
dist/ \
build/ \
*.egg-info/
.PHONY: clean help
clean:
@echo "Cleaning up cache files..."
@# Remove directories and files based on patterns
@for pattern in $(CACHE_PATTERNS); do \
find . -name "$$pattern" -prune -exec rm -rf {} + 2>/dev/null || true; \
done
@echo "Cleanup complete."
help:
@echo "Usage: make [target]"
@echo ""
@echo "Targets:"
@fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##//'