From 26fe6d39eb84bc7e034145e43cf6d3282e94ee1c Mon Sep 17 00:00:00 2001 From: 20x-dz <113644268+20x-dz@users.noreply.github.com> Date: Thu, 22 Jun 2023 10:37:24 +0200 Subject: [PATCH] feat: add support for specifying a recipe file path (#67) --- action.yaml | 5 +++++ index.js | 7 ++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/action.yaml b/action.yaml index 74aadcb..fd694f6 100644 --- a/action.yaml +++ b/action.yaml @@ -48,6 +48,11 @@ inputs: default: '' description: Path to local Deployer binary. + recipe: + required: false + default: '' + description: Recipe file path. + ansi: required: false default: 'true' diff --git a/index.js b/index.js index ae8f382..b79dc71 100644 --- a/index.js +++ b/index.js @@ -106,6 +106,11 @@ async function dep() { } let cmd = core.getInput('dep').split(' ') + let recipe = core.getInput('recipe') + if (recipe !== '') { + recipe = `--file=${recipe}` + } + let ansi = core.getBooleanInput('ansi') ? '--ansi' : '--no-ansi' let verbosity = core.getInput('verbosity') let options = [] @@ -121,7 +126,7 @@ async function dep() { } try { - await $`php ${dep} ${cmd} --no-interaction ${ansi} ${verbosity} ${options}` + await $`php ${dep} ${cmd} ${recipe} --no-interaction ${ansi} ${verbosity} ${options}` } catch (err) { core.setFailed(`Failed: dep ${cmd}`) }