Skip to content

Simple Pipe

Simple Pipe #19

Workflow file for this run

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-gradle
name: Simple Pipe
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:
inputs:
myValues:
description: 'Values to pass to the jar'
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
- name: Build with Gradle
uses: gradle/gradle-build-action@bd5760595778326ba7f1441bcf7e88b49de61a25 # v2.6.0
with:
arguments: build
- name: Upload a Build Artifact
uses: actions/[email protected]
with:
# Artifact name
name: greetings-jar
# A file, directory or wildcard pattern that describes what to upload
path: build/libs
# The desired behavior if no files are found using
- name: Download a Build Artifact
uses: actions/[email protected]
with:
# Artifact name
name: greetings-jar
- shell: bash
run: java -jar greetings-actions.jar ${{ github.event.inputs.myValues }}
count-args:
runs-on: ubuntu-latest
steps:
- id: report-count
uses: sagehen03/arg-count-action@main
with:
arguments-to-count: ${{ github.event.inputs.myValues }}
- run: echo
- shell: bash
run: |
echo argument count is ${{ steps.report-count.outputs.arg-count }}