Skip to content

Update dev docs

Update dev docs #508

Workflow file for this run

# 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: Update dev docs
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *'
jobs:
build-cpp-doc:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
repository: apache/incubator-graphar
ref: main
- name: Install dependencies
run: sudo apt-get install -y doxygen
- name: Build Cpp docs
working-directory: cpp
run: |
mkdir build
cd build
cmake -DBUILD_DOCS_ONLY=ON ..
make docs
- name: Upload docs
uses: actions/upload-artifact@v4
with:
name: cpp-docs
path: ./cpp/build/docs_doxygen/html
build-java-doc:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
repository: apache/incubator-graphar
ref: main
- name: Build Java-info docs
working-directory: maven-projects/info
run: |
export JAVA_HOME=${JAVA_HOME_11_X64}
mvn javadoc:javadoc
- name: Upload docs
uses: actions/upload-artifact@v4
with:
name: java-info-docs
path: ./maven-projects/info/target/site/apidocs
- name: Install dependencies
run: |
# install the latest arrow deb to test arrow
wget -c https://apache.jfrog.io/artifactory/arrow/"$(lsb_release --id --short | tr 'A-Z' 'a-z')"/apache-arrow-apt-source-latest-$(lsb_release --codename --short).deb \
-P /tmp/
sudo apt-get install -y /tmp/apache-arrow-apt-source-latest-"$(lsb_release --codename --short)".deb
sudo apt-get update -y
# TODO: ISSUE-241
sudo apt install -y libarrow-dev=17.0.0-1 \
libarrow-dataset-dev=17.0.0-1 \
libarrow-acero-dev=17.0.0-1 \
libparquet-dev=17.0.0-1
sudo apt-get install libcurl4-openssl-dev -y
sudo apt-get install llvm-11 clang-11 lld-11 libclang-11-dev libz-dev -y
- name: Build Java-FFI docs
working-directory: maven-projects/java
run: |
export JAVA_HOME=${JAVA_HOME_11_X64}
mvn javadoc:javadoc
- name: Upload docs
uses: actions/upload-artifact@v4
with:
name: java-ffi-docs
path: ./maven-projects/java/graphar-javadoc
build-spark-docs:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
repository: apache/incubator-graphar
ref: main
- name: Build Spark Docs
working-directory: maven-projects/spark
run: |
export JAVA_HOME=${JAVA_HOME_11_X64}
# FIXME: the install is not necessary, but it is a workaround for the issue
mvn clean install -DskipTests -Dspotless.check.skip=true
mvn scala:doc
- name: Upload docs
uses: actions/upload-artifact@v4
with:
name: spark-docs
path: ./maven-projects/spark/graphar/target/site/scaladocs
build-pyspark-docs:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
repository: apache/incubator-graphar
ref: main
- name: Install Poetry
working-directory: pyspark
run: |
yes | sudo python3 -m pip install poetry --quiet
poetry env use python3
- name: Build PySpark Docs
working-directory: pyspark
run: |
make install_docs
make docs
- name: Upload docs
uses: actions/upload-artifact@v4
with:
name: pyspark-docs
path: ./pyspark/docs
build-python-docs:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
repository: apache/incubator-graphar
ref: main
- name: Install dependencies
run: |
# install the latest arrow deb to test arrow
wget -c https://apache.jfrog.io/artifactory/arrow/"$(lsb_release --id --short | tr 'A-Z' 'a-z')"/apache-arrow-apt-source-latest-$(lsb_release --codename --short).deb \
-P /tmp/
sudo apt-get install -y /tmp/apache-arrow-apt-source-latest-"$(lsb_release --codename --short)".deb
sudo apt-get update -y
sudo apt install -y libarrow-dev=17.0.0-1 \
libarrow-dataset-dev=17.0.0-1 \
libarrow-acero-dev=17.0.0-1 \
libparquet-dev=17.0.0-1
sudo apt-get install -y ccache libcurl4-openssl-dev
- name: Install Poetry
working-directory: python
run: |
yes | sudo python3 -m pip install poetry --quiet
poetry env use python3
- name: Build python Docs
working-directory: python
run: |
make install_docs
make docs
- name: Upload docs
uses: actions/upload-artifact@v4
with:
name: python-docs
path: ./python/docs
devdocs:
name: Fetch and update dev docs
needs:
- build-cpp-doc
- build-java-doc
- build-spark-docs
- build-pyspark-docs
- build-python-docs
if: github.repository == 'apache/incubator-graphar-website'
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18.x
- uses: pnpm/action-setup@v2
with:
version: 8
- name: Check out the incubator-graphar repository
uses: actions/checkout@v4
with:
repository: apache/incubator-graphar
path: incubator-graphar
ref: main
depth: 1
- name: Syncing the docs folder and remove incubator-graphar
run: |
rsync -av incubator-graphar/docs/ docs/
rm -rf incubator-graphar
- name: Download cpp docs
uses: actions/download-artifact@v4
with:
name: cpp-docs
path: ./static/docs/cpp
- name: Download java-ffi docs
uses: actions/download-artifact@v4
with:
name: java-ffi-docs
path: ./static/docs/java-ffi
- name: Download java-info docs
uses: actions/download-artifact@v4
with:
name: java-info-docs
path: ./static/docs/java-info
- name: Download spark docs
uses: actions/download-artifact@v4
with:
name: spark-docs
path: ./static/docs/spark
- name: Download pyspark docs
uses: actions/download-artifact@v4
with:
name: pyspark-docs
path: ./static/docs/pyspark
- name: Download python docs
uses: actions/download-artifact@v4
with:
name: python-docs
path: ./static/docs/python
- name: Install dependencies
run: pnpm install
- name: Build
run: |
pnpm run build
cp .asf.yaml build/.asf.yaml
- name: Check if build has changed
id: check_changes
run: |
git fetch origin asf-site
git diff --quiet origin/asf-site build/ || echo "::set-output name=changes::true"
- name: Deploy if changes
uses: peaceiris/actions-gh-pages@v3
if: ${{ steps.check_changes.outputs.changes == 'true' }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build
publish_branch: asf-site