mirror of
https://github.com/deployphp/action.git
synced 2025-06-28 20:24:14 +00:00
Proposal to support a different php binary (#82)
* feat: Support different php binary. * feat: Support different php binary. --------- Co-authored-by: Nikolaj Stockholm <info@nikolajstockholm.dk>
This commit is contained in:
parent
6242095e72
commit
deec530661
3 changed files with 16 additions and 1 deletions
8
index.js
8
index.js
|
@ -124,9 +124,15 @@ async function dep() {
|
|||
} catch (e) {
|
||||
console.error('Invalid JSON in options')
|
||||
}
|
||||
|
||||
let phpBin = 'php'
|
||||
let phpBinArg = core.getInput('php-binary');
|
||||
if (phpBinArg !== '') {
|
||||
phpBin = phpBinArg
|
||||
}
|
||||
|
||||
try {
|
||||
await $`php ${dep} ${cmd} ${recipe} --no-interaction ${ansi} ${verbosity} ${options}`
|
||||
await $`${phpBin} ${dep} ${cmd} ${recipe} --no-interaction ${ansi} ${verbosity} ${options}`
|
||||
} catch (err) {
|
||||
core.setFailed(`Failed: dep ${cmd}`)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue