Bump to version 1.16 #70
Workflow file for this run
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
# Licensed to the Apache Software Foundation (ASF) under one or more | |
# contributor license agreements. See the NOTICE file distributed with | |
# this work for additional information regarding copyright ownership. | |
# The ASF licenses this file to You under the Apache License, Version 2.0 | |
# (the "License"); you may not use this file except in compliance with | |
# the License. You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 | |
# | |
# Unless required by applicable law or agreed to in writing, software | |
# distributed under the License is distributed on an "AS IS" BASIS, | |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
# See the License for the specific language governing permissions and | |
# limitations under the License. | |
name: NiFi Daffodil Processors | |
on: [push, pull_request] | |
jobs: | |
test: | |
name: Java ${{ matrix.java_version }}, ${{ matrix.os }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
java_version: [ 8, 11, 17 ] | |
os: [ ubuntu-latest, windows-latest ] | |
include: | |
- is_release_job: false | |
- is_release_job: true | |
java_version: 8 | |
os: ubuntu-latest | |
steps: | |
############################################################ | |
# Setup | |
############################################################ | |
- name: Checkout Repository | |
uses: actions/[email protected] | |
- name: Install Java | |
uses: actions/setup-java@v1 | |
with: | |
java-version: ${{ matrix.java_version }} | |
############################################################ | |
# Build/Test/Package | |
############################################################ | |
- name: Compile | |
run: mvn compile test-compile | |
- name: Test | |
run: mvn test | |
- name: Install | |
run: mvn install -DskipTests | |
############################################################ | |
# Create release if tagged | |
############################################################ | |
- name: Release Info | |
id: release_info | |
run: | | |
if [[ '${{ github.ref }}' == refs/tags/v* ]] && [[ '${{ matrix.is_release_job }}' == 'true' ]] | |
then | |
echo is_release=true >> $GITHUB_OUTPUT | |
echo tag=$(echo ${{ github.ref }} | cut -dv -f2) >> $GITHUB_OUTPUT | |
else | |
echo is_release=false >> $GITHUB_OUTPUT | |
fi | |
shell: bash | |
- name: Create Release | |
id: create_release | |
if: steps.release_info.outputs.is_release == 'true' | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ github.ref }} | |
release_name: v${{ steps.release_info.outputs.tag }} | |
draft: false | |
prerelease: false | |
- name: Upload Release Artifact | |
if: steps.release_info.outputs.is_release == 'true' | |
uses: actions/[email protected] | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
# This pulls from the CREATE RELEASE step above, referencing it's ID to | |
# get its outputs object, which include a `upload_url` | |
upload_url: ${{ steps.create_release.outputs.upload_url }} | |
asset_path: ./nifi-daffodil-nar/target/nifi-daffodil-nar-${{ steps.release_info.outputs.tag }}.nar | |
asset_name: nifi-daffodil-nar-${{ steps.release_info.outputs.tag }}.nar | |
asset_content_type: application/zip |