Skip to content

Commit

Permalink
Entire tso command enclosed in double apostrophes
Browse files Browse the repository at this point in the history
Signed-off-by: Martin Zeithaml <[email protected]>
  • Loading branch information
Martin-Zeithaml committed Nov 6, 2023
1 parent be11ee2 commit cde40d7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bin/libs/zos-dataset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ export function tsoIsDatasetExists(datasetName: string): number {
}

export function createDataSet(dsName: string, dsOptions: string): number {
const result=zoslib.tsoCommand(`"ALLOCATE NEW DA('${dsName}') ${dsOptions}"`);
const result=zoslib.tsoCommand(`ALLOCATE NEW DA('${dsName}') ${dsOptions}`);
return result.rc;
}

Expand Down
2 changes: 1 addition & 1 deletion bin/libs/zos.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import * as shell from './shell';
import * as stringlib from './string';

export function tsoCommand(...args:string[]): { rc: number, out: string } {
let message="tsocmd "+args.join(' ');
let message = "tsocmd " + '"' + args.join(' ') + '"';
common.printDebug('- '+message);
//we echo at the end to avoid a configmgr quirk where trying to read stdout when empty can hang waiting for bytes
const result = shell.execOutSync('sh', '-c', `${message} 2>&1 && echo '.'`);
Expand Down

0 comments on commit cde40d7

Please sign in to comment.