-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
92 lines (68 loc) · 1.57 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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
#################################################################
TESTDIR:=src/kimchima/tests/
##############################Legacy#############################
.PHONY: setup
setup:
python setup.py sdist bdist_wheel
.PHONY: upload
upload:
twine upload dist/* --verbose
################################Poetry################################
.PHONY: poetry
poetry:
@pipx install poetry==1.8.2
.PHONY: build
build:
@poetry build
.PHONY: lock
lock:
@poetry lock
.PHONY: shell
shell:
@poetry shell
.PHONY: install
install:
@poetry install -vvv --no-root
.PHONY: install-dev
install-dev:
@poetry install --only dev -vvv --no-root
.PHONY: format
format:
@ruff format
.PHONY: lint
lint:
@ruff check --output-format=github .
.PHONY: test
test:
@poetry run python -m pytest -v
# build and publish
.PHONY: publish
publish:
@poetry publish --build
# list current configuration
.PHONY: config
config:
@poetry config --list
.PHONY: source
source:
@poetry config repositories.source https://pypi.org/project/kimchima
.PHONY: prepare
prepare: poetry install-dev
###################################################################################################
# Commit and recommit changes to github
.PONY: commit
commit:
@echo "Committing changes..."
@git add .
@git commit -s -m"${message}"
@git push origin ${branch}
@git log -1
@echo "Changes committed and pushed to github."
.PONY: recommit
recommit:
@echo "Committing changes..."
@git add .
@git commit -s --amend --no-edit
@git push -f origin ${branch}
@git log -1
@echo "Changes committed and pushed to github."