fix newline issues when passing args directly to binary instead of bash

This commit is contained in:
David Hiendl 2024-01-19 14:46:55 +01:00
parent 38f11894b5
commit 90bbf0c643
2 changed files with 10 additions and 2 deletions

6
dist/index.js vendored
View File

@ -30214,10 +30214,14 @@ async function installFpmViaRuby(debug) {
async function executeFpmBuild(computedFpmArgs, debug) {
const userFpmArgs = _actions_core__WEBPACK_IMPORTED_MODULE_0__.getInput('fpm_args');
const fpmCmd = 'fpm'
let fpmCmd = 'fpm'
+ ' ' + computedFpmArgs
+ ' ' + userFpmArgs;
fpmCmd = fpmCmd.replaceAll('\n', ' ')
.replaceAll('\\n', ' ')
.replaceAll('\\', ' ');
if (debug) {
console.log('fpm command: ', fpmCmd);
}

View File

@ -20,10 +20,14 @@ export async function installFpmViaRuby(debug) {
export async function executeFpmBuild(computedFpmArgs, debug) {
const userFpmArgs = core.getInput('fpm_args');
const fpmCmd = 'fpm'
let fpmCmd = 'fpm'
+ ' ' + computedFpmArgs
+ ' ' + userFpmArgs;
fpmCmd = fpmCmd.replaceAll('\n', ' ')
.replaceAll('\\n', ' ')
.replaceAll('\\', ' ');
if (debug) {
console.log('fpm command: ', fpmCmd);
}