Skip to content

Test github action with manual boolean inputs #13

Test github action with manual boolean inputs

Test github action with manual boolean inputs #13

Workflow file for this run

name: Test github action with manual boolean inputs
on:
workflow_call:
inputs:
passed_true:
type: boolean
required: true
passed_false:
type: boolean
required: true
undefined:
type: boolean
workflow_dispatch:
inputs:
passed_true:
type: boolean
required: true
passed_false:
type: boolean
required: true
undefined:
type: boolean
jobs:
show-inputs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Print inputs
run: |
echo "passed_true: '${{ inputs.passed_true }}'"
echo "passed_false: '${{ inputs.passed_false }}'"
echo "undefined: '${{ inputs.undefined }}'"
shell: bash
- name: Tree .github
if: ${{ !inputs.passed_true }}
run: tree .github/
shell: bash
- uses: ./.github/actions/composite
if: ${{ inputs.passed_true }}
if-true:
if: ${{ inputs.passed_true }}
runs-on: ubuntu-latest
steps:
- name: Print
run: echo "Hello World"
if-not-true:
if: ${{ !inputs.passed_true }}
runs-on: ubuntu-latest
steps:
- name: Print
run: echo "Hello World"
if-false:
if: ${{ inputs.passed_false }}
runs-on: ubuntu-latest
steps:
- name: Print
run: echo "Hello World"
if-not-false:
if: ${{ !inputs.passed_false }}
runs-on: ubuntu-latest
steps:
- name: Print
run: echo "Hello World"
if-undefined:
if: ${{ inputs.undefined }}
runs-on: ubuntu-latest
steps:
- name: Print
run: echo "Hello World"
if-not-undefined:
if: ${{ !inputs.undefined }}
runs-on: ubuntu-latest
steps:
- name: Print
run: echo "Hello World"