Skip to content

Commit

Permalink
Merge branch 'develop' into dependabot/pip/urllib3-2.2.3
Browse files Browse the repository at this point in the history
  • Loading branch information
jpower432 authored Nov 25, 2024
2 parents a24cb5a + 9f1edcf commit b4d060c
Show file tree
Hide file tree
Showing 342 changed files with 15,313 additions and 13,964 deletions.
3 changes: 3 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# These owners will be the default owners for everything in
# the repo.
* @oscal-compass/compliance-trestle-maintainers
75 changes: 75 additions & 0 deletions .github/workflows/docs-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
name: Trestle Docs update
on:
push:
branches:
- develop
tags:
- v*

jobs:
set-versions:
runs-on: ubuntu-latest
outputs:
min: ${{ steps.versions.outputs.min }}
max: ${{ steps.versions.outputs.max }}
steps:
- uses: actions/checkout@v4
- id: versions
run: |
min_version=$(jq '.PYTHON_MIN' -r version.json)
max_version=$(jq '.PYTHON_MAX' -r version.json)
echo "min=$min_version"
echo "max=$max_version"
echo "min=$min_version" >> $GITHUB_OUTPUT
echo "max=$max_version" >> $GITHUB_OUTPUT
mike-version:
runs-on: ubuntu-latest
needs: [ set-versions]
outputs:
mver: ${{ steps.versions.mver }}
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ needs.set-versions.outputs.max }}
uses: actions/setup-python@v5
# This is deliberately not using a custom credential as it relies on native github actions token to have push rights.
with:
python-version: ${{ needs.set-versions.outputs.max }}
- id: versions
run: |
mike_version=$(python ./scripts/check-version.py ${{ env.GITHUB_REF }})
echo "mver=$mike_version" >> $GITHUB_OUTPUT
deploy-docs:
runs-on: ubuntu-latest
needs: [ mike-version ]
steps:
- uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ secrets.APP_ID }}
private-key: ${{ secrets.PRIVATE_KEY }}
- uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 0
token: ${{ steps.app-token.outputs.token }}
- name: Set up Python ${{ needs.set-versions.outputs.max }}
uses: actions/setup-python@v5
# This is deliberately not using a custom credential as it relies on native github actions token to have push rights.
with:
python-version: ${{ needs.set-versions.outputs.max }}
- name: Install build tools
run: |
make develop
- name: Install documenation dependencies
run: |
make docs-ubuntu-deps
- name: Create release
shell: bash
run: |
mike deploy ${{ needs.mike-version.outputs.mver }}
- name: Ensure latest is latest
shell: bash
run: |
mike set-default latest
36 changes: 4 additions & 32 deletions .github/workflows/python-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,10 @@ jobs:
continue-on-error: true
run: |
make code-typing
- name: Install documenation dependencies
if: steps.core-version.outputs.core == 'true'
run: |
make docs-ubuntu-deps
- name: Validate website content (mkdocs)
if: steps.core-version.outputs.core == 'true'
run: |
Expand Down Expand Up @@ -149,38 +153,6 @@ jobs:
with:
github_token: ${{ steps.app-token.outputs.token }}

deploy-docs:
runs-on: ubuntu-latest
needs: [ deploy, set-versions ]
concurrency:
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.job }}-docs
cancel-in-progress: true
# Temporary hack: allow develop as well as master to deploy docs.
if: github.ref == 'refs/heads/main'
steps:
- uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ secrets.APP_ID }}
private-key: ${{ secrets.PRIVATE_KEY }}
- uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 0
token: ${{ steps.app-token.outputs.token }}
- name: Set up Python ${{ needs.set-versions.outputs.max }}
uses: actions/setup-python@v5
# This is deliberately not using a custom credential as it relies on native github actions token to have push rights.
with:
python-version: ${{ needs.set-versions.outputs.max }}
- name: Install build tools
run: |
make develop
- name: Create release
shell: bash
run: |
mkdocs gh-deploy
merge-main-to-develop:
name: Merge main -> develop
runs-on: ubuntu-latest
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/python-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,9 @@ jobs:
continue-on-error: true
run: |
make code-typing
- name: Install documenation dependencies
run: |
make docs-ubuntu-deps
- name: Validate website content (mkdocs)
run: |
make docs-validate
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,5 @@ tmp_bin_test

/venv.trestle/

# mkdocs
.cache/
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ repos:
rev: 0.7.17
hooks:
- id: mdformat
exclude: "CHANGELOG.md|docs/mkdocs_code_of_conduct.md|docs/maintainers.md|docs/api_reference|tests/data/author|docs/contributing/mkdocs_contributing.md|tests/data/jinja_markdown_include|tests/data/jinja_cmd/number_captions_data.md|tests/data/jinja_cmd/number_captions_expected_output.md"
exclude: "CHANGELOG.md|docs/contributing/maintainers.md|docs/reference/API|tests/data/author|docs/contributing/index.md|tests/data/jinja_markdown_include|tests/data/jinja_cmd/number_captions_data.md|tests/data/jinja_cmd/number_captions_expected_output.md"
additional_dependencies:
- mdformat-tables
- mdformat-config
Expand Down
Loading

0 comments on commit b4d060c

Please sign in to comment.