mirror of
https://github.com/querydsl/querydsl.git
synced 2026-07-03 21:07:49 +08:00
64 lines
1.8 KiB
YAML
64 lines
1.8 KiB
YAML
name: querydsl
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- '*'
|
|
paths-ignore:
|
|
- README.md
|
|
|
|
pull_request:
|
|
branches:
|
|
- '*'
|
|
paths-ignore:
|
|
- README.md
|
|
|
|
jobs:
|
|
build:
|
|
env:
|
|
MAVEN_OPTS: -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn
|
|
|
|
strategy:
|
|
matrix:
|
|
maven-args:
|
|
- --activate-profiles all,travis,examples --projects !querydsl-scala
|
|
- --activate-profiles jpa,hibernate5,travis,examples --projects !querydsl-jpa-codegen
|
|
- --activate-profiles all,travis --projects querydsl-scala --resume-from querydsl-scala
|
|
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Check out code
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Set up JDK 1.8
|
|
uses: actions/setup-java@v1
|
|
with:
|
|
java-version: 1.8
|
|
|
|
- name: Start test databases
|
|
run: docker-compose --file travis/docker-compose.yml up --detach mysql postgresql mongo
|
|
|
|
- name: Initialize cache
|
|
uses: actions/cache@v1
|
|
with:
|
|
path: ~/.m2/repository
|
|
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
|
|
|
|
- name: Run tests
|
|
run: mvn --batch-mode install -am jacoco:report ${{ matrix.maven-args }}
|
|
|
|
- name: Report coverage
|
|
if: ${{ github.event_name == 'push' && github.ref == 'master' }}
|
|
env:
|
|
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
|
|
run: mvn --batch-mode coveralls:report
|
|
|
|
- name: Deploy snapshot 🚀
|
|
if: ${{ github.event_name == 'push' && github.ref == 'master' }}
|
|
env:
|
|
NEXUS_USERNAME: ${{ secrets.NEXUS_USERNAME }}
|
|
NEXUS_PASSWORD: ${{ secrets.NEXUS_PASSWORD }}
|
|
run: mvn deploy --settings deploy/.m2/settings.xml -DskipTests
|
|
|
|
- name: Clean up before caching
|
|
run: rm -rf ~/.m2/repository/com/querydsl/ |