This is an automated email from the ASF dual-hosted git repository. jiayu pushed a commit to branch fix-ci in repository https://gitbox.apache.org/repos/asf/sedona-spatialbench.git
commit 19fcd1cfc1245785d7aa155805cc645e308dedb8 Author: Jia Yu <[email protected]> AuthorDate: Wed Sep 17 17:33:15 2025 -0700 Fix the CI --- .github/workflows/packaging.yml | 108 +++++++++++++++++++++ .gitkeep | 0 docs-overrides/{ => .icons}/sedona_logo.png | Bin docs-overrides/{ => .icons}/sedona_logo_symbol.png | Bin docs-overrides/{ => .icons}/sedona_logo_symbol.svg | 0 mkdocs.yml | 8 +- 6 files changed, 109 insertions(+), 7 deletions(-) diff --git a/.github/workflows/packaging.yml b/.github/workflows/packaging.yml new file mode 100644 index 0000000..507ba95 --- /dev/null +++ b/.github/workflows/packaging.yml @@ -0,0 +1,108 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +name: Build and Deploy Docs + +on: + push: + branches: + - main + pull_request: + branches: + - main + +permissions: + contents: write + +concurrency: + group: ${{ github.repository }}-${{ github.ref }}-${{ github.workflow }} + cancel-in-progress: true + +jobs: + build-docs: + name: Build Documentation + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - uses: actions/setup-python@v5 + with: + python-version: "3.x" + + - name: Install docs requirements + run: pip install -r docs/requirements.txt + + - name: Build documentation + # Using mkdocs build is the standard way to generate the site + run: mkdocs build --strict + + - name: Compress docs for artifact upload + run: | + # The update-asf-site job expects a specific folder name inside the tarball + cp -R site documentation-site + tar -czf docs.tgz documentation-site + + - name: Upload docs artifact + uses: actions/upload-artifact@v4 + with: + name: docs + retention-days: 2 + path: docs.tgz + + update-asf-site: + name: Deploy Dev Snapshot + runs-on: ubuntu-latest + needs: + - build-docs + # This job should only run on pushes to the main branch + if: github.event_name == 'push' && github.ref == 'refs/heads/main' + + steps: + - uses: actions/download-artifact@v4 + with: + name: docs + + - name: Clone asf-site branch + uses: actions/checkout@v4 + with: + ref: asf-site + path: pages-clone + + - name: Update development documentation + run: | + git config --global user.email "[email protected]" + git config --global user.name "GitHub Actions" + + cd pages-clone + # Remove all existing content except .git directory + find . -maxdepth 1 -not -name '.git' -not -name '.' -exec rm -rf {} + + + tar -xf ../docs.tgz + # Move all content from documentation-site to root of asf-site branch + mv documentation-site/* . + mv documentation-site/.* . 2>/dev/null || true + rmdir documentation-site + + git add * + git commit --allow-empty -m"update documentation for main branch" + + - name: Push development documentation to asf-site + # Ensure this push only happens on the intended repository + if: success() && github.repository == 'apache/sedona-spatialbench' + run: | + cd pages-clone + git push \ No newline at end of file diff --git a/.gitkeep b/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/docs-overrides/sedona_logo.png b/docs-overrides/.icons/sedona_logo.png similarity index 100% rename from docs-overrides/sedona_logo.png rename to docs-overrides/.icons/sedona_logo.png diff --git a/docs-overrides/sedona_logo_symbol.png b/docs-overrides/.icons/sedona_logo_symbol.png similarity index 100% rename from docs-overrides/sedona_logo_symbol.png rename to docs-overrides/.icons/sedona_logo_symbol.png diff --git a/docs-overrides/sedona_logo_symbol.svg b/docs-overrides/.icons/sedona_logo_symbol.svg similarity index 100% rename from docs-overrides/sedona_logo_symbol.svg rename to docs-overrides/.icons/sedona_logo_symbol.svg diff --git a/mkdocs.yml b/mkdocs.yml index dd33807..3385978 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -52,10 +52,6 @@ theme: - navigation.tabs - navigation.tabs.sticky extra: - version: - provider: mike - default: - - latest social: - icon: fontawesome/brands/github link: 'https://github.com/apache/spatialbench' @@ -103,9 +99,7 @@ markdown_extensions: - pymdownx.tilde plugins: - search: - # prebuild_index: true + prebuild_index: true - macros - git-revision-date-localized: type: datetime - - mike: - canonical_version: 'latest'
