Java CI with Maven #1412
This file contains hidden or 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
| # This workflow will build a Java project with Maven | |
| # For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven | |
| name: Java CI with Maven | |
| on: | |
| schedule: | |
| - cron: '1 */12 * * 1' | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v1 | |
| - name: Set up JDK 1.8 | |
| uses: actions/setup-java@v1 | |
| with: | |
| java-version: 1.8 | |
| - name: package with Maven | |
| run: mvn -B package --file pom.xml | |
| - name: java run | |
| run: java -jar target/github-dns.jar | |
| - name: commit | |
| run: | | |
| git config --global user.email [email protected] | |
| git config --global user.name FuLin | |
| git add -A | |
| git commit -m 'git Action commit' -a | |
| - name: push | |
| uses: ad-m/github-push-action@master | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} |