Skip to content

Commit 9b38e38

Browse files
author
colinmcneil
committed
Sanitize pat when displaying args for debug
1 parent 3c6ab1a commit 9b38e38

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/utils/promptRunner.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,8 @@ export const getRunArgs = async (promptRef: string, projectDir: string, username
6060

6161
export const spawnPromptImage = async (promptArg: string, projectDir: string, username: string, platform: string, pat: string, callback: (json: any) => Promise<void>, token: CancellationToken) => {
6262
const args = await getRunArgs(promptArg!, projectDir!, username, platform, pat);
63-
callback({ method: 'message', params: { debug: `Running ${args.join(' ')}` } });
63+
const argsString = args.join(' ').replace(/dckr_pat_.*$/g, 'dckr_pat_****');
64+
callback({ method: 'message', params: { debug: `Running ${argsString}` } });
6465
const childProcess = spawn("docker", args);
6566
const pid = childProcess.pid;
6667

0 commit comments

Comments
 (0)