Created
December 18, 2018 13:25
-
-
Save dkelosky/765717a49d18f054ce53c97d4e10869f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/env node | |
import * as config from "config"; | |
import { execSync } from "child_process"; | |
import { DataSets } from "./doc/IDataSets"; | |
const hlq: string = config.get<string>('settings.hlq'); | |
const dataSets: DataSets = config.get<DataSets>('dataSets'); | |
Object.keys(dataSets).forEach((key) => { | |
const cmd = `zowe files create pds ` + | |
`"${hlq}.${key}" ` + | |
`--bs ${dataSets[key].blockSize} ` + | |
`--db ${dataSets[key].directoryBlocks} ` + | |
`--rf ${dataSets[key].recordFormat} ` + | |
`--rl ${dataSets[key].recordLength} ` + | |
`--dt ${dataSets[key].recordLength} ` + | |
`--sz ${dataSets[key].size}`; | |
console.log(cmd) | |
const resp = execSync(cmd).toString(); | |
console.log(resp.toString()) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment