| 123456789101112131415161718192021222324252627282930313233343536373839 |
- # This is a basic workflow to help you get started with Actions
- name: mirai-doc Publish
- # Controls when the action will run. Triggers the workflow on push or pull request
- # events but only for the master branch
- on:
- release:
- types:
- - created
- # A workflow run is made up of one or more jobs that can run sequentially or in parallel
- jobs:
- # This workflow contains a single job called "build"
- build:
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v2
- - name: Set up JDK 1.8
- uses: actions/setup-java@v1
- with:
- java-version: 1.8
- - name: Grant execute permission for gradlew
- run: chmod +x gradlew
- - name: Gradle build
- run: ./gradlew clean build # if test's failed, don't publish
- - name: Dokka
- run: ./gradlew :mirai-core-api:dokkaHtml
- - name: GitHub Pages Deploy
- uses: peaceiris/actions-gh-pages@v3
- with:
- personal_token: ${{ secrets.MAMOE_TOKEN }}
- publish_dir: ./mirai-core-api/build/dokka
- external_repository: project-mirai/mirai-doc
- publish_branch: master
- user_name: 'mamoebot'
- user_email: '[email protected]'
- keep_files: true
|