Fixed mishandling of variadic params in the presence expressions with… #65
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: Build | |
on: [push, pull_request] | |
jobs: | |
gradle-validation: | |
name: Gradle Wrapper | |
runs-on: ubuntu-latest | |
steps: | |
- name: Git Checkout | |
uses: actions/checkout@v2 | |
- name: Gradle Wrapper Validation | |
uses: gradle/wrapper-validation-action@v1 | |
test: | |
name: Test | |
needs: gradle-validation | |
runs-on: ubuntu-latest | |
steps: | |
- name: Setup Java | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- name: Git Checkout | |
uses: actions/checkout@v2 | |
- name: Setup Gradle Dependencies Cache | |
uses: actions/cache@v2 | |
with: | |
path: ~/.gradle/caches | |
key: ${{ runner.os }}-gradle-caches-${{ hashFiles('**/*.gradle', '**/*.gradle.kts', 'gradle.properties') }} | |
- name: Setup Gradle Wrapper Cache | |
uses: actions/cache@v2 | |
with: | |
path: ~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-wrapper-${{ hashFiles('**/gradle/wrapper/gradle-wrapper.properties') }} | |
- name: Run Tests | |
run: ./gradlew test | |
- name: Verify Plugin | |
run: ./gradlew verifyPlugin | |
build: | |
name: Build | |
needs: test | |
runs-on: ubuntu-latest | |
outputs: | |
name: ${{ steps.properties.outputs.name }} | |
version: ${{ steps.properties.outputs.version }} | |
changelog: ${{ steps.properties.outputs.changelog }} | |
pluginArchive: ${{ steps.properties.outputs.pluginArchive }} | |
steps: | |
- name: Setup Java | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- name: Git Checkout | |
uses: actions/checkout@v2 | |
- name: Setup Gradle Dependencies Cache | |
uses: actions/cache@v2 | |
with: | |
path: ~/.gradle/caches | |
key: ${{ runner.os }}-gradle-caches-${{ hashFiles('**/*.gradle', '**/*.gradle.kts', 'gradle.properties') }} | |
- name: Setup Gradle Wrapper Cache | |
uses: actions/cache@v2 | |
with: | |
path: ~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-wrapper-${{ hashFiles('**/gradle/wrapper/gradle-wrapper.properties') }} | |
- name: Set Properties | |
id: properties | |
shell: bash | |
run: | | |
PROPERTIES="$(./gradlew properties --console=plain -q)" | |
VERSION="$(echo "$PROPERTIES" | grep "^version:" | cut -f2- -d ' ')" | |
NAME="$(echo "$PROPERTIES" | grep "^pluginName:" | cut -f2- -d ' ')" | |
CHANGELOG="$(./gradlew getChangelog --unreleased --no-header --console=plain -q)" | |
CHANGELOG="${CHANGELOG//'%'/'%25'}" | |
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}" | |
CHANGELOG="${CHANGELOG//$'\r'/'%0D'}" | |
PLUGIN_ARCHIVE="${NAME}-${VERSION}.zip" | |
echo "::set-output name=version::$VERSION" | |
echo "::set-output name=name::$NAME" | |
echo "::set-output name=changelog::$CHANGELOG" | |
echo "::set-output name=pluginArchive::$PLUGIN_ARCHIVE" | |
- name: Build Plugin | |
run: ./gradlew buildPlugin | |
- name: Upload Built Plugin Artifact | |
uses: actions/upload-artifact@v2 | |
with: | |
name: ${{ steps.properties.outputs.pluginArchive }} | |
path: ./build/distributions/${{ steps.properties.outputs.pluginArchive }} | |
verify: | |
name: Verify | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Setup Java | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- name: Git Checkout | |
uses: actions/checkout@v2 | |
- name: Setup Gradle Dependencies Cache | |
uses: actions/cache@v2 | |
with: | |
path: ~/.gradle/caches | |
key: ${{ runner.os }}-gradle-caches-${{ hashFiles('**/*.gradle', '**/*.gradle.kts', 'gradle.properties') }} | |
- name: Setup Gradle Wrapper Cache | |
uses: actions/cache@v2 | |
with: | |
path: ~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-wrapper-${{ hashFiles('**/gradle/wrapper/gradle-wrapper.properties') }} | |
- name: Read Plugin Properties | |
id: properties | |
shell: bash | |
run: | | |
PROPERTIES="$(./gradlew properties --console=plain -q)" | |
IDE_VERSIONS="$(echo "$PROPERTIES" | grep "^pluginVerifierIdeVersions:" | base64)" | |
echo "::set-output name=ideVersions::$IDE_VERSIONS" | |
echo "::set-output name=verifierHome::~/.pluginVerifier" | |
- name: Setup Plugin Verifier IDEs Cache | |
uses: actions/cache@v2 | |
with: | |
path: ${{ steps.properties.outputs.verifierHome }}/ides | |
key: ${{ runner.os }}-plugin-verifier-${{ steps.properties.outputs.ideVersions }} | |
- name: Verify Plugin | |
run: ./gradlew runPluginVerifier -Pplugin.verifier.home.dir=${{ steps.properties.outputs.verifierHome }} | |
github-release: | |
name: Github Release | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') | |
needs: [build, verify] | |
runs-on: ubuntu-latest | |
steps: | |
- name: Git Checkout | |
uses: actions/checkout@v2 | |
- name: Download Plugin Artifact | |
id: download | |
uses: actions/download-artifact@v2 | |
with: | |
name: ${{ needs.build.outputs.pluginArchive }} | |
- name: Publish Github Release | |
id: publish-release | |
uses: ncipollo/release-action@v1 | |
with: | |
name: v${{ needs.build.outputs.version }} | |
body: ${{ needs.build.outputs.changelog }} | |
artifacts: ${{ steps.download.outputs.download-path }}${{ steps.properties.outputs.pluginArchive }} | |
artifactContentType: application/zip | |
token: ${{ secrets.PERSONAL_GITHUB_TOKEN }} |