Fixes #160 #77
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 | |
paths: | |
- '**/*' | |
- '!**/.github/workflows/**' | |
jobs: | |
mkdocs: | |
runs-on: ubuntu-latest | |
timeout-minutes: 45 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
# https://github.com/mkdocs/mkdocs/issues/2370 | |
with: | |
fetch-depth: 0 | |
- name: Set up Google Services | |
run: | | |
touch app/google-services.json | |
echo "${CONTENT// /}" | base64 --decode > app/google-services.json | |
env: | |
CONTENT: ${{ secrets.GOOGLE_SERVICES }} | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: 17 | |
distribution: 'zulu' | |
cache: gradle | |
- name: Setup Gradle | |
uses: gradle/gradle-build-action@v3 | |
- name: Set up Signing Key | |
run: | | |
touch app/key.jks | |
echo "${KEYSTORE// /}" | base64 --decode > app/key.jks | |
touch keystore.properties | |
echo "${KEYSTORE_PROPERTIES// /}" | base64 --decode > keystore.properties | |
env: | |
KEYSTORE: ${{ secrets.KEYSTORE }} | |
KEYSTORE_PROPERTIES: ${{ secrets.KEYSTORE_PROPERTIES }} | |
- name: Setup Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.10' | |
- name: Generate Docs | |
run: | | |
pip install mkdocs mkdocs-material Pygments | |
./gradlew dokkaGfmMultiModule --no-configuration-cache | |
mv build/dokka/gfmMultiModule docs | |
cat README.md > docs/index.md | |
mkdocs gh-deploy | |
# https://github.com/softprops/action-gh-release/issues/236 | |
permissions: | |
contents: write |