From c1eaa452191d94b0ca78b4793bcf29882c00c8ce Mon Sep 17 00:00:00 2001 From: Tim Jenness Date: Tue, 27 Feb 2024 16:21:47 -0700 Subject: [PATCH] Enable docstring validation action --- .github/workflows/docstyle.yaml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .github/workflows/docstyle.yaml diff --git a/.github/workflows/docstyle.yaml b/.github/workflows/docstyle.yaml new file mode 100644 index 0000000..2f22ba9 --- /dev/null +++ b/.github/workflows/docstyle.yaml @@ -0,0 +1,28 @@ +name: Run docstyle + +on: + push: + branches: + - main + pull_request: + +jobs: + call-workflow: + uses: lsst/rubin_workflows/.github/workflows/docstyle.yaml@main + with: + args: "python/" + numpydoc: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - name: Set up Python + uses: actions/setup-python@v4 + + - name: Install numpydoc + run: | + python -m pip install --upgrade pip + python -m pip install numpydoc + + - name: Validate docstrings + run: python -m numpydoc.hooks.validate_docstrings $(find python -name "*.py")