Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,41 @@ jobs:
run: >
julia --project=. --color=yes test/runtests.jl

docs-build:
name: Build Documentation
if: github.event_name == 'pull_request'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Check for docs/src changes
id: docs-changes
run: |
git fetch origin ${{ github.base_ref }}
CHANGED_FILES=$(git diff --name-only origin/${{ github.base_ref }}...HEAD)
echo "Changed files: $CHANGED_FILES"
if echo "$CHANGED_FILES" | grep -qE '^(src/|docs/)'; then
echo "docs_changed=true" >> $GITHUB_OUTPUT
else
echo "docs_changed=false" >> $GITHUB_OUTPUT
fi
- uses: julia-actions/setup-julia@v1
if: steps.docs-changes.outputs.docs_changed == 'true'
with:
version: '1'
arch: x64
- uses: julia-actions/cache@v1
if: steps.docs-changes.outputs.docs_changed == 'true'
- uses: julia-actions/julia-buildpkg@v1
if: steps.docs-changes.outputs.docs_changed == 'true'
- name: Build documentation
if: steps.docs-changes.outputs.docs_changed == 'true'
run: julia --project=. --color=yes docs/make.jl
- name: Skip docs build (no relevant changes)
if: steps.docs-changes.outputs.docs_changed == 'false'
run: echo "No docs or src changes detected, skipping docs build."

deploy-docs:
name: Deploy Documentation
# Only run deployment on pushes to main (after merge) or manual trigger
Expand Down
2 changes: 1 addition & 1 deletion docs/src/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ This section provides the documentation for linear transformations and related o
```@autodocs
Modules = [Linear_Algebra]
Order = [:function, :type]
Pages = [""linear_algebra_transform.jl"]
Pages = ["linear_algebra_transform.jl"]
```
Loading