Skip to content

Commit ef8acef

Browse files
authored
Add typos CI check (#1234)
Co-authored-by: simonhammes <[email protected]>
1 parent 612c59f commit ef8acef

File tree

3 files changed

+32
-6
lines changed

3 files changed

+32
-6
lines changed

.github/workflows/test.yml

+7
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,13 @@ jobs:
3333
- run: pip install '.[test]'
3434
- run: mypy
3535

36+
spell-check:
37+
runs-on: ubuntu-20.04
38+
steps:
39+
- uses: actions/checkout@v4
40+
- name: Check spelling
41+
uses: crate-ci/[email protected]
42+
3643
# Unit tests
3744
#
3845

.typos.toml

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
[files]
2+
extend-exclude = [
3+
"tests/facts/apt.SimulateOperationWillChange/upgrade.json",
4+
"tests/words.txt",
5+
]
6+
7+
[default]
8+
extend-ignore-re = [
9+
"shell\\('uptim'\\)",
10+
'"fpr:::::::::',
11+
'== "fpr":',
12+
"00740ba1",
13+
"forr something in",
14+
"unknown tag 'forr'",
15+
"nd6 options=",
16+
]
17+
18+
[default.extend-words]
19+
datas = "datas"

pyinfra/operations/docker.py

+6-6
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@ def container(
3030
+ networks: network list to attach on container
3131
+ ports: port list to expose
3232
+ volumes: volume list to map on container
33-
+ env_vars: environment varible list to inject on container
33+
+ env_vars: environment variable list to inject on container
3434
+ pull_always: force image pull
35-
+ force: remove a contaner with same name and create a new one
35+
+ force: remove a container with same name and create a new one
3636
+ present: whether the container should be up and running
3737
+ start: start or stop the container
3838
@@ -125,7 +125,7 @@ def image(image, present=True):
125125
Manage Docker images
126126
127127
+ image: Image and tag ex: nginx:alpine
128-
+ present: whether the Docker image should be exist
128+
+ present: whether the Docker image should exist
129129
130130
**Examples:**
131131
@@ -188,7 +188,7 @@ def volume(volume, driver="", labels=None, present=True):
188188
if present:
189189

190190
if existent_volume:
191-
host.noop("Volume alredy exist!")
191+
host.noop("Volume already exists!")
192192
return
193193

194194
yield handle_docker(
@@ -261,7 +261,7 @@ def network(
261261

262262
if present:
263263
if existent_network:
264-
host.noop("Alredy exist a network with {0} name!".format(network))
264+
host.noop("Network {0} already exists!".format(network))
265265
return
266266

267267
yield handle_docker(
@@ -284,7 +284,7 @@ def network(
284284

285285
else:
286286
if existent_network is None:
287-
host.noop("Ther is not network with {0} name!".format(network))
287+
host.noop("Network {0} does not exist!".format(network))
288288
return
289289

290290
yield handle_docker(

0 commit comments

Comments
 (0)