chore(ci): fixing github actions build job #405
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: docs | |
on: | |
push: | |
branches: | |
- main | |
env: | |
RUST_BACKTRACE: 1 | |
RUSTDOCFLAGS: --enable-index-page -Zunstable-options | |
jobs: | |
docs: | |
name: docs | |
runs-on: macos-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Install Rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: nightly | |
profile: minimal | |
- name: Cache LLVM and Clang | |
id: cache-llvm | |
uses: actions/cache@v2 | |
with: | |
path: | | |
C:/Program Files/LLVM | |
./llvm | |
key: llvm-15 | |
- name: Install LLVM and Clang | |
id: install-llvm | |
uses: KyleMayes/install-llvm-action@v1 | |
with: | |
version: 15 | |
cached: ${{ steps.cache-llvm.outputs.cache-hit }} | |
- name: Prepare LLVM | |
shell: bash | |
env: | |
LLVM_PATH: /Users/runner/work/rdfox-rs/rdfox-rs/llvm | |
LLVM_VERSION: ${{ steps.install-llvm.outputs.version }} | |
run: | | |
set -x | |
# export LLVM_PATH="$(brew --prefix llvm)" | |
"$LLVM_PATH/bin/clang" -v | |
echo "SDKROOT=$(xcrun --sdk macosx --show-sdk-path)" >> $GITHUB_ENV | |
echo "CPATH=$LLVM_PATH/lib/clang/$LLVM_VERSION/include/" >> $GITHUB_ENV | |
echo "LDFLAGS=-L$LLVM_PATH/lib" >> $GITHUB_ENV | |
echo "CPPFLAGS=-I$LLVM_PATH/include" >> $GITHUB_ENV | |
echo "CC=$LLVM_PATH/bin/clang" >> $GITHUB_ENV | |
echo "CXX=$LLVM_PATH/bin/clang++" >> $GITHUB_ENV | |
- name: Create rustdoc | |
run: cargo +nightly doc --verbose --no-deps --lib --bins --workspace --document-private-items | |
- name: Deploy | |
uses: JamesIves/github-pages-deploy-action@4.1.8 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
branch: gh-pages | |
folder: target/x86_64-apple-darwin/doc | |
clean: true | |
git-config-email: info@ekgf.org | |
repository-name: EKGF/rdfox-rs | |
commit-message: "Update" | |
single-commit: true |