Skip to content

chore: set workflow structure #12

chore: set workflow structure

chore: set workflow structure #12

Workflow file for this run

name: Build, Test and Deploy
on:
push
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
cache: maven
- name: Build with Maven Wrapper
run: ./mvnw clean verify
- name: Upload plugin update-site
uses: actions/upload-artifact@v3
with:
name: updatesite
path: com.developer.nefarious.zjoule.updatesite/target/repository/
release:
needs: release

Check failure on line 32 in .github/workflows/main.yaml

View workflow run for this annotation

GitHub Actions / Build, Test and Deploy

Invalid workflow file

The workflow is not valid. .github/workflows/main.yaml (Line: 32, Col: 12): Job 'release' depends on job 'release' which creates a cycle in the dependency graph. .github/workflows/main.yaml (Line: 46, Col: 12): Job 'javadoc' depends on job 'release' which creates a cycle in the dependency graph.
runs-on: ubuntu-latest
# if: github.ref == 'refs/heads/main'
steps:
- name: Download updatesite
uses: actions/download-artifact@v3
with:
name: updatesite
javadoc:
needs: release
runs-on: ubuntu-latest
# if: github.ref == 'refs/heads/main'
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
cache: maven
- name: Generate Javadoc
run: |
./mvnw javadoc:javadoc \
-pl com.developer.nefarious.zjoule.plugin
- name: Upload JavaDoc
uses: actions/upload-artifact@v3
with:
name: documentation
path: com.developer.nefarious.zjoule.plugin/target/reports/apidocs/
publish:
needs: javadoc
runs-on: ubuntu-latest
# if: github.ref == 'refs/heads/main'
permissions:
contents: write
steps:
- name: Download JavaDoc
uses: actions/download-artifact@v3
with:
name: documentation
# - name: Deploy to GitHub Pages
# uses: peaceiris/actions-gh-pages@v4
# with:
# github_token: ${{ secrets.GITHUB_TOKEN }}
# publish_dir: .
# publish_dir: ./public