Skip to content

Move Documentation CI #9

Move Documentation CI

Move Documentation CI #9

Workflow file for this run

name: Documentation Check
on:
pull_request:
branches:
- main
jobs:
check-docs:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v2
- name: Install Homebrew
run: |
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
echo "/home/linuxbrew/.linuxbrew/bin" >> $GITHUB_PATH
- name: Install Sui using Homebrew
run: brew install sui
- name: Run documentation script
run: |
chmod +x ./scripts/docgen.sh
./scripts/docgen.sh
shell: bash
- name: Check for changes in move-docs directories
run: |
output=$(git status --porcelain | grep '^?? packages/.*/move-docs/' || true)
echo "Filtered git status output: $output"
if [[ -n "$output" ]]; then
echo "Changes in move-docs directories are not committed. Please commit these changes before merging."
exit 1 # Fail the job to indicate documentation is not up-to-date
else
echo "No changes in move-docs directories. Documentation is up-to-date."
fi
shell: bash