Update index.js

This commit is contained in:
Nova Cat 2025-01-22 17:24:21 -08:00
parent 22a8ea2dd1
commit 1073a5d68d

View file

@ -1,10 +1,12 @@
const { exec } = require('node:child_process');
var additional = process.env.INPUT_ADDITIONAL;
exec('apk add bash git ' + additional, (err, output) => {
if (err) {
console.log("Something went wrong...");
console.log(output);
} else {
console.log("Successfully installed packages!");
const { exec } = require('child_process');
exec('apk add bash git ' + additional, (error, stdout, stderr) => {
if (error) {
console.error(`Error: ${error.message}`);
return;
}
})
if (stderr) {
console.error(`Stderr: ${stderr}`);
return;
}
console.log(`Stdout: ${stdout}`);
});