Skip to content

Commit 5e88680

Browse files
committed
chore: fix formatting
1 parent 3eed96f commit 5e88680

File tree

1 file changed

+77
-79
lines changed

1 file changed

+77
-79
lines changed

Taskfile.yml

Lines changed: 77 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -1,86 +1,84 @@
1-
21
# https://taskfile.dev
32

43
version: "3"
54

65
env:
7-
LOCALES: ["de"] # list your included locales here, e.g. ["de", "fr"]
8-
TRANSLATIONS: "octoprint_pi_support/translations" # translations folder, do not touch
9-
6+
LOCALES: ["de"] # list your included locales here, e.g. ["de", "fr"]
7+
TRANSLATIONS: "octoprint_pi_support/translations" # translations folder, do not touch
108

119
tasks:
12-
install:
13-
desc: Installs the plugin into the current venv
14-
cmds:
15-
- "python -m pip install -e .[develop]"
16-
17-
test:
18-
desc: Run the plugin's test suite
19-
cmds:
20-
- "python -m pytest"
21-
22-
### Build related
23-
24-
build:
25-
desc: Builds sdist & wheel
26-
cmds:
27-
- python -m build --sdist --wheel
28-
29-
build-sdist:
30-
desc: Builds sdist
31-
cmds:
32-
- python -m build --sdist
33-
34-
build-wheel:
35-
desc: Builds wheel
36-
cmds:
37-
- python -m build --wheel
38-
39-
### Translation related
40-
41-
babel-new:
42-
desc: Create a new translation for a locale
43-
cmds:
44-
- task: babel-extract
45-
- |
46-
pybabel init --input-file=translations/messages.pot --output-dir=translations --locale="{{ .CLI_ARGS }}"
47-
48-
babel-extract:
49-
desc: Update pot file from source
50-
cmds:
51-
- pybabel extract --mapping-file=babel.cfg --output-file=translations/messages.pot [email protected] --copyright-holder="The OctoPrint Project" .
52-
53-
babel-update:
54-
desc: Update translation files from pot file
55-
cmds:
56-
- for:
57-
var: LOCALES
58-
cmd: pybabel update --input-file=translations/messages.pot --output-dir=translations --locale={{ .ITEM }}
59-
60-
babel-refresh:
61-
desc: Update translation files from source
62-
cmds:
63-
- task: babel-extract
64-
- task: babel-update
65-
66-
babel-compile:
67-
desc: Compile translation files
68-
cmds:
69-
- pybabel compile --directory=translations
70-
71-
babel-bundle:
72-
desc: Bundle translations
73-
preconditions:
74-
- test -d {{ .TRANSLATIONS }}
75-
cmds:
76-
- for:
77-
var: LOCALES
78-
cmd: |
79-
locale="{{ .ITEM }}"
80-
source="translations/${locale}"
81-
target="{{ .TRANSLATIONS }}/${locale}"
82-
83-
[ ! -d "${target}" ] || rm -r "${target}"
84-
85-
echo "Copying translations for locale ${locale} from ${source} to ${target}..."
86-
cp -r "${source}" "${target}"
10+
install:
11+
desc: Installs the plugin into the current venv
12+
cmds:
13+
- "python -m pip install -e .[develop]"
14+
15+
test:
16+
desc: Run the plugin's test suite
17+
cmds:
18+
- "python -m pytest"
19+
20+
### Build related
21+
22+
build:
23+
desc: Builds sdist & wheel
24+
cmds:
25+
- python -m build --sdist --wheel
26+
27+
build-sdist:
28+
desc: Builds sdist
29+
cmds:
30+
- python -m build --sdist
31+
32+
build-wheel:
33+
desc: Builds wheel
34+
cmds:
35+
- python -m build --wheel
36+
37+
### Translation related
38+
39+
babel-new:
40+
desc: Create a new translation for a locale
41+
cmds:
42+
- task: babel-extract
43+
- |
44+
pybabel init --input-file=translations/messages.pot --output-dir=translations --locale="{{ .CLI_ARGS }}"
45+
46+
babel-extract:
47+
desc: Update pot file from source
48+
cmds:
49+
- pybabel extract --mapping-file=babel.cfg --output-file=translations/messages.pot [email protected] --copyright-holder="The OctoPrint Project" .
50+
51+
babel-update:
52+
desc: Update translation files from pot file
53+
cmds:
54+
- for:
55+
var: LOCALES
56+
cmd: pybabel update --input-file=translations/messages.pot --output-dir=translations --locale={{ .ITEM }}
57+
58+
babel-refresh:
59+
desc: Update translation files from source
60+
cmds:
61+
- task: babel-extract
62+
- task: babel-update
63+
64+
babel-compile:
65+
desc: Compile translation files
66+
cmds:
67+
- pybabel compile --directory=translations
68+
69+
babel-bundle:
70+
desc: Bundle translations
71+
preconditions:
72+
- test -d {{ .TRANSLATIONS }}
73+
cmds:
74+
- for:
75+
var: LOCALES
76+
cmd: |
77+
locale="{{ .ITEM }}"
78+
source="translations/${locale}"
79+
target="{{ .TRANSLATIONS }}/${locale}"
80+
81+
[ ! -d "${target}" ] || rm -r "${target}"
82+
83+
echo "Copying translations for locale ${locale} from ${source} to ${target}..."
84+
cp -r "${source}" "${target}"

0 commit comments

Comments
 (0)