-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
47 lines (32 loc) · 877 Bytes
/
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
VERSION := $(shell egrep -o "([0-9]{1,}\.)+[0-9]{1,}" .bumpversion.cfg)
.PHONY: all project init dev pip build clean major minor patch release master lint test
all: project
project: clean lint test build
init: dev pip
dev:
deactivate | true
rm -rf venv
virtualenv venv -p python3.6
pip:
. ./venv/bin/activate && pip install -r requirements.txt
build:
mkdir -p build/src/ses_account_monitor
find ./ses_account_monitor -name '*.py' | cpio -pdm ./build/src
cp lambda_handler.py ./build/src
cd build/src && zip -r9 ../lambda-ses-account-monitor.py.zip .
clean:
rm -rf build
major: lint test
bumpversion major
minor: lint test
bumpversion minor
patch: lint test
bumpversion patch
release: master
git push origin v${VERSION}
master:
git push origin master
lint:
flake8 ses_account_monitor lambda_handler.py
test:
pytest -vv --cov=./ses_account_monitor