-
Notifications
You must be signed in to change notification settings - Fork 0
/
lets.yaml
111 lines (97 loc) · 2.5 KB
/
lets.yaml
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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
shell: bash
env:
DOCKER_BUILDKIT: "1"
COMPOSE_DOCKER_CLI_BUILD: "1"
CURRENT_UID:
sh: echo "`id -u`:`id -g`"
commands:
build-dev:
description: build dev image
cmd: |
docker build \
-f Dockerfile \
-t featureflags-client \
--target dev \
.
build-test:
description: build test image
cmd: |
docker build \
-f Dockerfile \
-t featureflags-client-test \
--target test \
.
build-docs:
description: build docs image
cmd: |
docker build \
-f Dockerfile \
-t featureflags-client-docs \
--target docs \
.
build-examples:
description: build examples image
cmd: |
docker build \
-f Dockerfile \
-t featureflags-client-examples \
--target examples \
.
test:
description: run tests
depends: [ build-test ]
cmd: |
export ARGS="$@"
docker-compose run --rm test
ishell:
description: Run app with ipython
depends: [ build-examples ]
cmd: docker-compose run --rm ishell
gen-docs:
description: generate docs
depends: [ build-docs ]
cmd: docker-compose run --rm docs
ruff:
description: Run ruff and fix errors
depends: [ build-dev ]
cmd: |
docker-compose run -T --rm featureflags-client \
pdm run ruff ${LETS_COMMAND_ARGS}
ruff-diff:
description: Run ruff to check diff
depends: [ build-dev ]
cmd: |
docker-compose run -T --rm featureflags-client \
pdm run ruff-diff ${LETS_COMMAND_ARGS}
mypy:
description: Run mypy
depends: [ build-dev ]
cmd: |
docker-compose run -T --rm featureflags-client \
pdm run mypy ${LETS_COMMAND_ARGS}
black:
description: Run black
depends: [ build-dev ]
cmd: |
docker-compose run -T --rm featureflags-client \
pdm run black ${LETS_COMMAND_ARGS}
fmt:
description: Run black and ruff
depends: [ build-dev ]
cmd: |
docker-compose run -T --rm featureflags-client \
pdm run fmt
release:
description: |
Update version in featureflags_client/__init__.py
Create new annotated tag
Push changes to remote
options: |
Usage: lets release <version> --message=<message>
Options:
<version> Set version
--message=<message>, -m Release message
Example:
lets release 0.4.0 --message="Added feature"
cmd: |
VERSION=${LETSOPT_VERSION} MESSAGE=${LETSOPT_MESSAGE} pdm run release