Skip to content
Closed
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
52 changes: 52 additions & 0 deletions .github/workflows/publish-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Build and Publish Docs

on:
push:
branches:
- main
paths:
- 'geospatial-studio-sdk/docs/**'
- '.github/workflows/publish-docs.yml'
pull_request:
branches:
- main
paths:
- 'geospatial-studio-sdk/docs/**'
- '.github/workflows/publish-docs.yml'
types: [opened, synchronize, reopened]

jobs:
build-and-deploy:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.11'

- name: Install poetry
run: pip install poetry

- name: Install dependencies
working-directory: ./geospatial-studio-sdk
run: poetry install

- name: Build documentation
working-directory: ./geospatial-studio-sdk
run: poetry run docs-build

- name: Deploy to GitHub Pages
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./geospatial-studio-sdk/sdk-docs-site
publish_branch: gh-pages
cname: terrastackai.github.io
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -176,3 +176,4 @@ resources.qrc
*.geostudio_apikey*
tasks/
*.geostudio_config_file*
geospatial-studio-sdk/docs/examples/
Loading