Skip to content

Commit 59cf4d2

Browse files
authored
Merge pull request #27 from sandialabs/final-tweaks
Final tweaks
2 parents 06237fb + ccfa0d9 commit 59cf4d2

22 files changed

+402
-12
lines changed

.github/workflows/continuous-integration.yml

+15-1
Original file line numberDiff line numberDiff line change
@@ -40,13 +40,27 @@ jobs:
4040
run: python3 -m pip install .
4141

4242
- name: Test with pytest
43-
run: python3 -m pytest --cov=staged_script test/
43+
run: python3 -m pytest --cov=staged_script example/ test/
4444

4545
- name: Upload coverage reports to Codecov
4646
uses: codecov/codecov-action@v4
4747
env:
4848
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
4949

50+
- name: Check documentation spelling
51+
run: make spelling
52+
working-directory: ./doc
53+
54+
- name: Check documentation coverage
55+
run: make coverage
56+
working-directory: ./doc
57+
58+
- name: Archive documentation coverage results
59+
uses: actions/upload-artifact@v3
60+
with:
61+
name: docs-coverage-report
62+
path: doc/build/coverage/python.txt
63+
5064
- name: Test uninstall
5165
run: python3 -m pip uninstall -y reverse_argparse
5266

.pre-commit-config.yaml

-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ repos:
1010
rev: v0.5.0
1111
hooks:
1212
- id: ruff
13-
args: [ --fix ]
1413
- id: ruff-format
1514

1615
- repo: https://github.com/pre-commit/mirrors-mypy

.readthedocs.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,4 @@ python:
2323
path: .
2424
- requirements: requirements.txt
2525
- requirements: doc/requirements.txt
26+
- requirements: example/requirements.txt

CHANGELOG.md

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# CHANGELOG
2+
3+
4+
5+
## v1.0.0 (2024-06-25)
6+
This file will be overwritten when Semantic Release next runs.

CONTRIBUTING.md

+3-9
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,5 @@
11
# Contributing to `staged-script`
22

3-
> **Usage Guidelines:**
4-
>
5-
> * Review all the text and add/remove/adjust things as needed.
6-
> * Delete this note.
7-
83
Thanks so much for your willingness to help out with `staged-script`'s
94
development :grinning: Here's everything you need to know.
105

@@ -77,6 +72,7 @@ The checks we perform are the following:
7772
* Use [ruff][ruff] to lint and format the code and docstrings.
7873
* Use [mypy][mypy] to run static type checking on our type-hinted code.
7974
* Ensure no large files are added to the repository.
75+
* Ensure files parse as valid Python.
8076
* Check for files that would conflict in case-sensitive filesystems.
8177
* Ensure files don't contain merge conflict strings.
8278
* Ensure files end with a single blank line.
@@ -87,8 +83,6 @@ The checks we perform are the following:
8783
* Use [doc8][doc8] to enforce our style for our documentation.
8884
* Use [pyroma][pyroma] to ensure our package complies with the best practices
8985
of the Python packaging ecosystem.
90-
* INSERT OTHERS
91-
* AS NEEDED
9286

9387
[ruff]: https://docs.astral.sh/ruff/
9488
[mypy]: https://github.com/python/mypy
@@ -142,12 +136,12 @@ search for and install them. These are the ones we recommend:
142136
[GitKraken][kraken] into VS Code.
143137
* **IntelliCode:** AI-assisted development features.
144138
* **Pre-Commit:** Commands and helpers for executing pre-commit hooks.
139+
* **Test Adapter Converter:** Converts from the Test Explorer UI (below) API
140+
to native VS Code testing.
145141
* **Test Explorer UI:** Extensible user interface for running your tests in VS
146142
Code.
147143
* **Vim:** For when you can't truly leave vi behind (and who would want to?).
148144
* **vscode-icons:** Icons for the file explorer.
149-
* INSERT OTHERS
150-
* AS NEEDED
151145

152146
[conventional]: https://www.conventionalcommits.org/en/v1.0.0/
153147
[kraken]: https://www.gitkraken.com/

doc/requirements.txt

+1
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,4 @@ sphinx-copybutton
66
sphinx-rtd-theme
77
sphinxcontrib-mermaid
88
sphinxcontrib-programoutput
9+
sphinxcontrib-spelling

doc/source/conf.py

+1
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
"sphinx_rtd_theme",
3434
"sphinxcontrib.mermaid",
3535
"sphinxcontrib.programoutput",
36+
"sphinxcontrib.spelling",
3637
]
3738
intersphinx_mapping = {"python": ("https://docs.python.org/3", None)}
3839

doc/source/spelling_wordlist.txt

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
pre
2+
erroring
3+
retryable
4+
programmatically
5+
linters
6+
namespace
7+
argparse
8+
ArgumentGroup

example/ex_0_the_basics.py

100644100755
+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#!/usr/bin/env python3
12
"""A very basic staged script."""
23

34
# © 2024 National Technology & Engineering Solutions of Sandia, LLC

example/ex_1_removing_the_retry_arguments.py

100644100755
+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#!/usr/bin/env python3
12
"""A staged script without retry arguments."""
23

34
# © 2024 National Technology & Engineering Solutions of Sandia, LLC

example/ex_2_running_certain_stages_by_default.py

100644100755
+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#!/usr/bin/env python3
12
"""A staged script that runs certain stages by default."""
23

34
# © 2024 National Technology & Engineering Solutions of Sandia, LLC

example/ex_3_adding_arguments.py

100644100755
+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#!/usr/bin/env python3
12
"""A staged script with additional arguments."""
23

34
# © 2024 National Technology & Engineering Solutions of Sandia, LLC

example/ex_4_customizing_stage_behavior.py

100644100755
+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#!/usr/bin/env python3
12
"""A staged script with custom stage behavior."""
23

34
# © 2024 National Technology & Engineering Solutions of Sandia, LLC

example/ex_5_customizing_individual_stages.py

100644100755
+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#!/usr/bin/env python3
12
"""A staged script with phases customized per stage."""
23

34
# © 2024 National Technology & Engineering Solutions of Sandia, LLC

example/ex_6_creating_retryable_stages.py

100644100755
+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#!/usr/bin/env python3
12
"""A staged script with a retryable stage."""
23

34
# © 2024 National Technology & Engineering Solutions of Sandia, LLC

example/ex_7_customizing_the_summary.py

100644100755
+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#!/usr/bin/env python3
12
"""A staged script with a retryable stage."""
23

34
# © 2024 National Technology & Engineering Solutions of Sandia, LLC

example/requirements.txt

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Requirements for running the `staged-script` examples.

0 commit comments

Comments
 (0)