chore: fix env spread lint
This commit is contained in:
@@ -133,12 +133,13 @@ export function createBashTool(
|
|||||||
const workdir = params.workdir?.trim() || process.cwd();
|
const workdir = params.workdir?.trim() || process.cwd();
|
||||||
|
|
||||||
const { shell, args: shellArgs } = getShellConfig();
|
const { shell, args: shellArgs } = getShellConfig();
|
||||||
|
const env = params.env ? { ...process.env, ...params.env } : process.env;
|
||||||
const child: ChildProcessWithoutNullStreams = spawn(
|
const child: ChildProcessWithoutNullStreams = spawn(
|
||||||
shell,
|
shell,
|
||||||
[...shellArgs, params.command],
|
[...shellArgs, params.command],
|
||||||
{
|
{
|
||||||
cwd: workdir,
|
cwd: workdir,
|
||||||
env: { ...process.env, ...(params.env ?? {}) },
|
env,
|
||||||
detached: true,
|
detached: true,
|
||||||
stdio: ["pipe", "pipe", "pipe"],
|
stdio: ["pipe", "pipe", "pipe"],
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user