I am trying to setup a custom action for GitHub Actions and currently this is what I have:
name: 'Install Dependencies'
inputs:
os:
description: 'The OS to fetch the dependencies for'
required: True
runs:
using: "composite"
steps:
- run: echo I am a test
shell: bash
if: startsWith(os, 'Linux')
What I am trying to do is to eventually have a bunch of different shell scripts that are tailored to do the job for a specific OS and therefore in my action, I want to select the appropriate script based on the os parameter that was passed into it.
When I am invoking the action as shown above though, I get Unexpected value 'if'. So my question is: How can I only run execute the run command if a condition is met?