-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
75 lines (61 loc) · 1.74 KB
/
Makefile
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
default: list
# define install_repo
# @echo Checking out $(1)
# @git clone -q $(1) 2> /dev/null && echo cloning || { echo "$(1) already exists"; }
# cd $(shell echo $(1) | sed -n -e 's/^.*\/\([^.]*\)\(.git\)*/\1/p') \
# && git checkout $(2) \
# && git status
# endef
#
# define update_repo
# @echo Checking out $(1)
# @git clone -q $(1) 2> /dev/null && echo cloning || { echo "$(1) already exists"; }
# cd $(shell echo $(1) | sed -n -e 's/^.*\/\([^.]*\)\(.git\)*/\1/p') \
# && git checkout $(2) \
# && git pull
# endef
# Clean out all Pythonic cruft
clean:
@find . -regex '^.*\(__pycache__\|\.py[co]\)$$' -delete;
@find . -type d -name __pycache__ -exec rm -r {} \+
@find . -type d -name '*.egg-info' -exec rm -rf {} +
@find . -type d -name .mypy_cache -exec rm -r {} \+
@rm -rf .pytest_cache;
@rm -rf tests/.pytest_cache;
@rm -rf dist build
@rm -f .coverage*
@echo Finished cleaning out pythonic cruft...
install:
@echo Installing package
pip install .
init:
@echo Initializing repos
morq init
update:
@echo Update all repos
morq update
list:
@echo Listing all repos
@morq list
list_installed:
@echo Listing all repos
@morq list -i
check:
@echo Check all repos for valid versions
morq check
# SubRepos should all have a docs/ folder which we use implicitly
# For project that support auto-doc (like Python), Sphinx should run autodocs on it
docs:
# Spawn master build on docs
@echo building docs
morq docs
build:
@echo Build the entire project
@echo Not sure how to do it yet
@echo Each project should provide its own "make build" command independently.
@echo * Try not to build the same project twice: IE: do we build a dependency tree?
test:
pytest tests
format:
isort .
black .