Skip to content

Mixed inputs

Mixed inputs #3

Workflow file for this run

# https://github.blog/changelog/2021-11-10-github-actions-input-types-for-manual-workflows/
name: Mixed inputs
on:
workflow_dispatch:
inputs:
message:
required: true
name:
type: choice
description: Who to greet
options:
- monalisa
- cschleiden
use-emoji:
type: boolean
description: Include 🎉🤣 emojis
jobs:
greet:
runs-on: ubuntu-latest
steps:
- name: Send greeting
run: echo $MESSAGE ${{ toJSON(inputs.name) }} ${{ fromJSON('["", "🥳"]')[inputs.use-emoji == 'true'] }}
env:
MESSAGE: ${{ inputs.message }}