From 3b5867b05513b2bb02f3389a3193b334a2ee230e Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 10:41:26 -0700 Subject: [PATCH 01/12] update deployment --- .github/workflows/coverage.yml | 30 ---------------- .github/workflows/deployment.yml | 54 +++++++++++++++++++++++++++++ .github/workflows/documentation.yml | 33 ------------------ README.rst | 5 +++ 4 files changed, 59 insertions(+), 63 deletions(-) delete mode 100644 .github/workflows/coverage.yml create mode 100644 .github/workflows/deployment.yml delete mode 100644 .github/workflows/documentation.yml diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml deleted file mode 100644 index 29bea256..00000000 --- a/.github/workflows/coverage.yml +++ /dev/null @@ -1,30 +0,0 @@ -name: Coverage Report - -on: [push, pull_request] - -jobs: - coverage: - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v2 - - - name: Set up Python - uses: actions/setup-python@v2 - with: - python-version: '3.8' - - - name: Install dependencies - run: | - python -m pip install --upgrade pip - pip install .[dev] - - - name: Run tests with coverage - run: | - pytest --cov=quends --cov-report=html - - - name: Deploy coverage report to GitHub Pages - uses: peaceiris/actions-gh-pages@v3 - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: ./htmlcov \ No newline at end of file diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml new file mode 100644 index 00000000..62d6362c --- /dev/null +++ b/.github/workflows/deployment.yml @@ -0,0 +1,54 @@ +name: Deploy to GitHub Pages + +on: + push: + branches: + - main # Change this to your main branch if different + +permissions: + contents: write # Grant write access to repository contents + +jobs: + deploy: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v2 + + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: '3.8' # Specify your Python version + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install .[dev] # Install your development dependencies + + - name: Build Sphinx documentation + run: | + sphinx-build -b html docs docs/_build/html # Adjust paths as necessary + + - name: Run tests with coverage + run: | + pytest --cov=quends --cov-report=html # Run tests and generate coverage report + + - name: Prepare coverage report for deployment + run: | + mkdir -p docs/_build/html/coverage # Create a directory for coverage reports + cp -r htmlcov/* docs/_build/html/coverage/ # Copy coverage report to the new directory + + - name: Deploy Sphinx documentation to GitHub Pages + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: docs/_build/html # Publish Sphinx documentation + publish_branch: gh-pages # Specify the branch to publish to + + - name: Deploy coverage report to GitHub Pages + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: docs/_build/html/coverage # Publish coverage report + publish_branch: gh-pages # Specify the branch to publish to diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml deleted file mode 100644 index d9d86934..00000000 --- a/.github/workflows/documentation.yml +++ /dev/null @@ -1,33 +0,0 @@ -name: documentation - -on: [push, pull_request, workflow_dispatch] - -permissions: - contents: write - -jobs: - docs: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - with: - python-version: '3.9' - - name: Install dependencies - run: | - pip install sphinx sphinx_rtd_theme myst_parser sphinx-book-theme - pip install .[dev] - - name: List files - run: | - ls -R - - name: Sphinx build - run: | - sphinx-build -b html docs docs/_build/html - - name: Deploy to GitHub Pages - uses: peaceiris/actions-gh-pages@v3 - if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }} - with: - publish_branch: gh-pages - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: docs/_build/html - force_orphan: true \ No newline at end of file diff --git a/README.rst b/README.rst index 9fe5274d..39ced4fe 100644 --- a/README.rst +++ b/README.rst @@ -97,3 +97,8 @@ Note, to combine the coverage data from all the tox environments run: - :: PYTEST_ADDOPTS=--cov-append tox + +Coverage +========== + +You can view the coverage report [here](coverage/). \ No newline at end of file From b7fabfaf638950d6290ef58134432c1a3454a2a4 Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 10:57:53 -0700 Subject: [PATCH 02/12] update deployment --- .github/workflows/deployment.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index 62d6362c..d4e38e7f 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -24,6 +24,7 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip + pip install sphinx sphinx_rtd_theme myst_parser sphinx-book-theme pip install .[dev] # Install your development dependencies - name: Build Sphinx documentation From 3c325bcdb628c0d4d355bbca69f15ebe031e0ed0 Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 11:40:52 -0700 Subject: [PATCH 03/12] update deployment --- .github/workflows/deployment.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index d4e38e7f..448d7fa1 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -53,3 +53,4 @@ jobs: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: docs/_build/html/coverage # Publish coverage report publish_branch: gh-pages # Specify the branch to publish to + force_orphan: true # Optional: Create an orphan branch for coverage From 4a779e2a1a457041a709bc05db5e14b48d6ecbc8 Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 11:46:23 -0700 Subject: [PATCH 04/12] Update deployment --- .github/workflows/deployment.yml | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index 448d7fa1..f17567d6 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -40,17 +40,10 @@ jobs: mkdir -p docs/_build/html/coverage # Create a directory for coverage reports cp -r htmlcov/* docs/_build/html/coverage/ # Copy coverage report to the new directory - - name: Deploy Sphinx documentation to GitHub Pages + - name: Deploy to GitHub Pages uses: peaceiris/actions-gh-pages@v3 with: github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: docs/_build/html # Publish Sphinx documentation + publish_dir: docs/_build/html # Publish Sphinx documentation and coverage report publish_branch: gh-pages # Specify the branch to publish to - - - name: Deploy coverage report to GitHub Pages - uses: peaceiris/actions-gh-pages@v3 - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: docs/_build/html/coverage # Publish coverage report - publish_branch: gh-pages # Specify the branch to publish to - force_orphan: true # Optional: Create an orphan branch for coverage + force_orphan: true # Optional: Create an orphan branch \ No newline at end of file From 48415c5187ee5c6823f80a92fde419be53312806 Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 10:41:26 -0700 Subject: [PATCH 05/12] update deployment --- .github/workflows/deployment.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index f17567d6..99209828 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -24,7 +24,10 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip +<<<<<<< HEAD pip install sphinx sphinx_rtd_theme myst_parser sphinx-book-theme +======= +>>>>>>> 3b5867b (update deployment) pip install .[dev] # Install your development dependencies - name: Build Sphinx documentation From cbc9964a620da332e8d8cfe49d5aedb28bd2d30b Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 10:57:53 -0700 Subject: [PATCH 06/12] update deployment --- .github/workflows/deployment.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index 99209828..3d6314fe 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -24,10 +24,14 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip +<<<<<<< HEAD <<<<<<< HEAD pip install sphinx sphinx_rtd_theme myst_parser sphinx-book-theme ======= >>>>>>> 3b5867b (update deployment) +======= + pip install sphinx sphinx_rtd_theme myst_parser sphinx-book-theme +>>>>>>> b7fabfa (update deployment) pip install .[dev] # Install your development dependencies - name: Build Sphinx documentation From f2b58103ec2cc25b4fc5188af4bbae658edb60cb Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 10:41:26 -0700 Subject: [PATCH 07/12] update deployment --- .github/workflows/deployment.yml | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index 3d6314fe..c90afb2d 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -3,7 +3,8 @@ name: Deploy to GitHub Pages on: push: branches: - - main # Change this to your main branch if different + - main # Trigger on pushes to the main branch + workflow_dispatch: # Allow manual triggering permissions: contents: write # Grant write access to repository contents @@ -24,14 +25,7 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip -<<<<<<< HEAD -<<<<<<< HEAD pip install sphinx sphinx_rtd_theme myst_parser sphinx-book-theme -======= ->>>>>>> 3b5867b (update deployment) -======= - pip install sphinx sphinx_rtd_theme myst_parser sphinx-book-theme ->>>>>>> b7fabfa (update deployment) pip install .[dev] # Install your development dependencies - name: Build Sphinx documentation @@ -53,4 +47,4 @@ jobs: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: docs/_build/html # Publish Sphinx documentation and coverage report publish_branch: gh-pages # Specify the branch to publish to - force_orphan: true # Optional: Create an orphan branch \ No newline at end of file + force_orphan: true # Optional: Create an orphan branch for coverage From 0d6860c74008e6ffc71e7152f7dabfe1f05d432b Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 11:40:52 -0700 Subject: [PATCH 08/12] update deployment --- .github/workflows/deployment.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index c90afb2d..5fa2f82e 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -47,4 +47,4 @@ jobs: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: docs/_build/html # Publish Sphinx documentation and coverage report publish_branch: gh-pages # Specify the branch to publish to - force_orphan: true # Optional: Create an orphan branch for coverage + force-orphan: True \ No newline at end of file From 5f9d38a746da98aa24803aae1c2142de6f4bb885 Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 12:36:17 -0700 Subject: [PATCH 09/12] update deployment --- .github/workflows/deployment.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index 5fa2f82e..0b55fbbc 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -47,4 +47,6 @@ jobs: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: docs/_build/html # Publish Sphinx documentation and coverage report publish_branch: gh-pages # Specify the branch to publish to + force_orphan: true # Optional: Create an orphan branch + force-orphan: True \ No newline at end of file From 2753ad5cb09cc5600e4cb849c573d4bea2733304 Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 12:36:55 -0700 Subject: [PATCH 10/12] update deployment --- .github/workflows/deployment.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index 0b55fbbc..467d472f 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -48,5 +48,3 @@ jobs: publish_dir: docs/_build/html # Publish Sphinx documentation and coverage report publish_branch: gh-pages # Specify the branch to publish to force_orphan: true # Optional: Create an orphan branch - - force-orphan: True \ No newline at end of file From 871585ba624538a825f08695b4aa91bd64057d59 Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 10:41:26 -0700 Subject: [PATCH 11/12] update deployment --- .github/workflows/deployment.yml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index 467d472f..e2cfcf5f 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -41,10 +41,17 @@ jobs: mkdir -p docs/_build/html/coverage # Create a directory for coverage reports cp -r htmlcov/* docs/_build/html/coverage/ # Copy coverage report to the new directory - - name: Deploy to GitHub Pages + - name: Deploy Sphinx documentation to GitHub Pages uses: peaceiris/actions-gh-pages@v3 with: github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: docs/_build/html # Publish Sphinx documentation and coverage report + publish_dir: docs/_build/html # Publish Sphinx documentation + publish_branch: gh-pages # Specify the branch to publish to + + - name: Deploy coverage report to GitHub Pages + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: docs/_build/html/coverage # Publish coverage report publish_branch: gh-pages # Specify the branch to publish to force_orphan: true # Optional: Create an orphan branch From 02ba14ae479028ef33c26db286a6beb014410563 Mon Sep 17 00:00:00 2001 From: Abeyah Calpatura Date: Tue, 22 Apr 2025 10:41:26 -0700 Subject: [PATCH 12/12] update deployment --- .github/workflows/deployment.yml | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index e2cfcf5f..2587d2d1 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -3,8 +3,7 @@ name: Deploy to GitHub Pages on: push: branches: - - main # Trigger on pushes to the main branch - workflow_dispatch: # Allow manual triggering + - main # Change this to your main branch if different permissions: contents: write # Grant write access to repository contents @@ -41,17 +40,10 @@ jobs: mkdir -p docs/_build/html/coverage # Create a directory for coverage reports cp -r htmlcov/* docs/_build/html/coverage/ # Copy coverage report to the new directory - - name: Deploy Sphinx documentation to GitHub Pages + - name: Deploy to GitHub Pages uses: peaceiris/actions-gh-pages@v3 with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: docs/_build/html # Publish Sphinx documentation publish_branch: gh-pages # Specify the branch to publish to - - - name: Deploy coverage report to GitHub Pages - uses: peaceiris/actions-gh-pages@v3 - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: docs/_build/html/coverage # Publish coverage report - publish_branch: gh-pages # Specify the branch to publish to - force_orphan: true # Optional: Create an orphan branch + force_orphan: true