diff --git a/.eslintrc.js b/.eslintrc.js index 2e3218d37f..20b722d1da 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -25,6 +25,7 @@ module.exports = { ], "rules": { "@typescript-eslint/no-magic-numbers": "off", + "@typescript-eslint/no-restricted-imports": "off", "jest/expect-expect": ["warn", { "assertFunctionNames": ["expect*", "**.*expect*"] }], @@ -64,6 +65,11 @@ module.exports = { "ignoreEnums": true, "ignoreReadonlyClassProperties": true }], + "@typescript-eslint/no-restricted-imports": ["error", { + "patterns": [{ + "group": ["**/../lib", "**/../src"] + }] + }], "@typescript-eslint/no-unused-vars": "off", "@typescript-eslint/no-var-requires": "off", "@typescript-eslint/semi": "warn", diff --git a/__tests__/__packages__/cli-test-utils/package.json b/__tests__/__packages__/cli-test-utils/package.json index 40a1cfb090..56cf637de5 100644 --- a/__tests__/__packages__/cli-test-utils/package.json +++ b/__tests__/__packages__/cli-test-utils/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/cli-test-utils", - "version": "8.6.1", + "version": "8.6.2", "description": "Test utilities package for Zowe CLI plug-ins", "author": "Zowe", "license": "EPL-2.0", @@ -43,7 +43,7 @@ "devDependencies": { "@types/js-yaml": "^4.0.9", "@types/uuid": "^10.0.0", - "@zowe/imperative": "8.6.1" + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/imperative": "^8.0.0" diff --git a/lerna.json b/lerna.json index 7d52575206..4f3a18280a 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "8.6.1", + "version": "8.6.2", "command": { "publish": { "ignoreChanges": [ diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index face8cd51d..698b56ff0e 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -52,7 +52,7 @@ }, "__tests__/__packages__/cli-test-utils": { "name": "@zowe/cli-test-utils", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "dependencies": { "find-up": "^5.0.0", @@ -63,7 +63,7 @@ "devDependencies": { "@types/js-yaml": "^4.0.9", "@types/uuid": "^10.0.0", - "@zowe/imperative": "8.6.1" + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/imperative": "^8.0.0" @@ -16267,21 +16267,21 @@ }, "packages/cli": { "name": "@zowe/cli", - "version": "8.6.1", + "version": "8.6.2", "hasInstallScript": true, "license": "EPL-2.0", "dependencies": { - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1", - "@zowe/provisioning-for-zowe-sdk": "8.6.1", - "@zowe/zos-console-for-zowe-sdk": "8.6.1", - "@zowe/zos-files-for-zowe-sdk": "8.6.1", - "@zowe/zos-jobs-for-zowe-sdk": "8.6.1", - "@zowe/zos-logs-for-zowe-sdk": "8.6.1", - "@zowe/zos-tso-for-zowe-sdk": "8.6.1", - "@zowe/zos-uss-for-zowe-sdk": "8.6.1", - "@zowe/zos-workflows-for-zowe-sdk": "8.6.1", - "@zowe/zosmf-for-zowe-sdk": "8.6.1", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2", + "@zowe/provisioning-for-zowe-sdk": "8.6.2", + "@zowe/zos-console-for-zowe-sdk": "8.6.2", + "@zowe/zos-files-for-zowe-sdk": "8.6.2", + "@zowe/zos-jobs-for-zowe-sdk": "8.6.2", + "@zowe/zos-logs-for-zowe-sdk": "8.6.2", + "@zowe/zos-tso-for-zowe-sdk": "8.6.2", + "@zowe/zos-uss-for-zowe-sdk": "8.6.2", + "@zowe/zos-workflows-for-zowe-sdk": "8.6.2", + "@zowe/zosmf-for-zowe-sdk": "8.6.2", "find-process": "1.4.7", "lodash": "4.17.21", "minimatch": "9.0.5", @@ -16294,7 +16294,7 @@ "@types/diff": "^5.0.9", "@types/lodash": "^4.17.6", "@types/tar": "^6.1.11", - "@zowe/cli-test-utils": "8.6.1", + "@zowe/cli-test-utils": "8.6.2", "comment-json": "^4.2.3", "strip-ansi": "^6.0.1", "which": "^4.0.0" @@ -16350,15 +16350,15 @@ }, "packages/core": { "name": "@zowe/core-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "dependencies": { "comment-json": "~4.2.3", "string-width": "^4.2.3" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/imperative": "8.6.2" }, "engines": { "node": ">=18.12.0" @@ -16369,7 +16369,7 @@ }, "packages/imperative": { "name": "@zowe/imperative", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "dependencies": { "@types/yargs": "^17.0.32", @@ -16563,16 +16563,16 @@ }, "packages/provisioning": { "name": "@zowe/provisioning-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "dependencies": { "js-yaml": "^4.1.0" }, "devDependencies": { "@types/js-yaml": "^4.0.9", - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "engines": { "node": ">=18.12.0" @@ -16597,15 +16597,15 @@ }, "packages/workflows": { "name": "@zowe/zos-workflows-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "dependencies": { - "@zowe/zos-files-for-zowe-sdk": "8.6.1" + "@zowe/zos-files-for-zowe-sdk": "8.6.2" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "engines": { "node": ">=18.12.0" @@ -16617,12 +16617,12 @@ }, "packages/zosconsole": { "name": "@zowe/zos-console-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "engines": { "node": ">=18.12.0" @@ -16634,17 +16634,17 @@ }, "packages/zosfiles": { "name": "@zowe/zos-files-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "dependencies": { "lodash": "^4.17.21", "minimatch": "^9.0.5" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1", - "@zowe/zos-uss-for-zowe-sdk": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2", + "@zowe/zos-uss-for-zowe-sdk": "8.6.2" }, "engines": { "node": ">=18.12.0" @@ -16676,15 +16676,15 @@ }, "packages/zosjobs": { "name": "@zowe/zos-jobs-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "dependencies": { - "@zowe/zos-files-for-zowe-sdk": "8.6.1" + "@zowe/zos-files-for-zowe-sdk": "8.6.2" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "engines": { "node": ">=18.12.0" @@ -16696,12 +16696,12 @@ }, "packages/zoslogs": { "name": "@zowe/zos-logs-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "engines": { "node": ">=18.12.0" @@ -16713,12 +16713,12 @@ }, "packages/zosmf": { "name": "@zowe/zosmf-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "engines": { "node": ">=18.12.0" @@ -16730,15 +16730,15 @@ }, "packages/zostso": { "name": "@zowe/zos-tso-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "dependencies": { - "@zowe/zosmf-for-zowe-sdk": "8.6.1" + "@zowe/zosmf-for-zowe-sdk": "8.6.2" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "engines": { "node": ">=18.12.0" @@ -16750,15 +16750,15 @@ }, "packages/zosuss": { "name": "@zowe/zos-uss-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "license": "EPL-2.0", "dependencies": { "ssh2": "^1.15.0" }, "devDependencies": { "@types/ssh2": "^1.11.19", - "@zowe/cli-test-utils": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/imperative": "8.6.2" }, "engines": { "node": ">=18.12.0" diff --git a/packages/cli/CHANGELOG.md b/packages/cli/CHANGELOG.md index 5d1347a6bc..f553ae64fb 100644 --- a/packages/cli/CHANGELOG.md +++ b/packages/cli/CHANGELOG.md @@ -2,10 +2,16 @@ All notable changes to the Zowe CLI package will be documented in this file. + +## `8.6.2` + +- BugFix: Resolved issue where `zowe zos-files upload file-to-uss` was not properly handling command flags. [#2234](https://github.com/zowe/zowe-cli/pull/2334) + ## `8.6.1` - BugFix: Fixed an issue where the `zowe zos-logs list logs` command could fail or not return all logs if a start time was not supplied. [#2336](https://github.com/zowe/zowe-cli/pull/2336) + ## `8.6.0` - Enhancement: Added support for running applications on TSO/E address spaces. Start applications and receive/transmit messages using the new `tso start`, `tso receive` and `tso send` commands. [#2280](https://github.com/zowe/zowe-cli/pull/2280) diff --git a/packages/cli/__tests__/zosfiles/__unit__/upload/ftu/FileToUSS.handler.unit.test.ts b/packages/cli/__tests__/zosfiles/__unit__/upload/ftu/FileToUSS.handler.unit.test.ts index e4a6582d25..5956179949 100644 --- a/packages/cli/__tests__/zosfiles/__unit__/upload/ftu/FileToUSS.handler.unit.test.ts +++ b/packages/cli/__tests__/zosfiles/__unit__/upload/ftu/FileToUSS.handler.unit.test.ts @@ -185,5 +185,95 @@ describe("Upload file-to-uss handler", () => { expect(apiMessage).toMatchSnapshot(); expect(logMessage).toMatchSnapshot(); }); + it("should upload a file to a USS if requested - zosattributes file - binary", async () => { + // Require the handler and create a new instance + const handlerReq = require("../../../../../src/zosfiles/upload/ftu/FileToUSS.handler"); + const handler = new handlerReq.default(); + const inputfile = "test-file"; + const USSFileName = "testing"; + let zosAttributes: any; + + let error; + let apiMessage = ""; + let jsonObj; + let logMessage = ""; + let fakeSession = null; + + jest.spyOn(ZosFilesAttributes, "loadFromFile").mockImplementation(() => { + zosAttributes = Object.create(ZosFilesAttributes.prototype); + zosAttributes.attributes = new Map([ + ['*.json', { ignore: true }], + ['*.bin', { ignore: false, localEncoding: 'binary', remoteEncoding: 'binary' }], + ['*.jcl', { ignore: false, localEncoding: 'IBM-1047', remoteEncoding: 'IBM-1047' }], + ['*.md', { ignore: false, localEncoding: 'UTF-8', remoteEncoding: 'UTF-8' }], + ['*.txt', { ignore: false, localEncoding: 'binary', remoteEncoding: 'binary' }] + ]); + zosAttributes.basePath = undefined; + return zosAttributes; + }); + Upload.uploadFile = jest.fn(async (session, file, name, options = {}) => { + fakeSession = session; + return { + success: true, + commandResponse: "uploaded", + apiResponse: [ + { success: true, from: inputfile, to: USSFileName } + ] + }; + }); + try { + await handler.process({ + arguments: { + $0: "fake", + _: ["fake"], + inputfile, + USSFileName, + ...UNIT_TEST_ZOSMF_PROF_OPTS + }, + response: { + data: { + setMessage: jest.fn((setMsgArgs) => { + apiMessage = setMsgArgs; + }), + setObj: jest.fn((setObjArgs) => { + jsonObj = setObjArgs; + }) + }, + console: { + log: jest.fn((logArgs) => { + logMessage += "\n" + logArgs; + }) + }, + progress: { + startBar: jest.fn(() => { + // do nothing + }), + endBar: jest.fn(() => { + // do nothing + }) + } + } + } as any); + } catch (e) { + error = e; + } + expect(error).toBeUndefined(); + expect(Upload.uploadFile).toHaveBeenCalledTimes(1); + expect(Upload.uploadFile).toHaveBeenCalledWith(fakeSession, inputfile, USSFileName, { + attributes: zosAttributes, + binary: undefined, + includeHidden: undefined, + maxConcurrentRequests: undefined, + responseTimeout: undefined, + task: { + percentComplete: 0, + stageName: 0, + statusMessage: "Uploading USS file" + } + }); + expect(jsonObj).toMatchSnapshot(); + expect(apiMessage).toMatchSnapshot(); + expect(logMessage).toMatchSnapshot(); + }); }); }); diff --git a/packages/cli/__tests__/zosfiles/__unit__/upload/ftu/__snapshots__/FileToUSS.handler.unit.test.ts.snap b/packages/cli/__tests__/zosfiles/__unit__/upload/ftu/__snapshots__/FileToUSS.handler.unit.test.ts.snap index f13e49cc22..f6a4e0d87a 100644 --- a/packages/cli/__tests__/zosfiles/__unit__/upload/ftu/__snapshots__/FileToUSS.handler.unit.test.ts.snap +++ b/packages/cli/__tests__/zosfiles/__unit__/upload/ftu/__snapshots__/FileToUSS.handler.unit.test.ts.snap @@ -1,5 +1,32 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP +exports[`Upload file-to-uss handler process method should upload a file to a USS if requested - zosattributes file - binary 1`] = ` +Object { + "apiResponse": Array [ + Object { + "from": "test-file", + "success": true, + "to": "testing", + }, + ], + "commandResponse": "uploaded", + "success": true, +} +`; + +exports[`Upload file-to-uss handler process method should upload a file to a USS if requested - zosattributes file - binary 2`] = `""`; + +exports[`Upload file-to-uss handler process method should upload a file to a USS if requested - zosattributes file - binary 3`] = ` +" +-  + success: true + from:  test-file + to:  testing + + +uploaded" +`; + exports[`Upload file-to-uss handler process method should upload a file to a USS if requested - zosattributes file 1`] = ` Object { "apiResponse": Array [ diff --git a/packages/cli/package.json b/packages/cli/package.json index d6270f3599..615c401698 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/cli", - "version": "8.6.1", + "version": "8.6.2", "zoweVersion": "v3.0.0", "description": "Zowe CLI is a command line interface (CLI) that provides a simple and streamlined way to interact with IBM z/OS.", "author": "Zowe", @@ -58,17 +58,17 @@ "preshrinkwrap": "node ../../scripts/rewriteShrinkwrap.js" }, "dependencies": { - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1", - "@zowe/provisioning-for-zowe-sdk": "8.6.1", - "@zowe/zos-console-for-zowe-sdk": "8.6.1", - "@zowe/zos-files-for-zowe-sdk": "8.6.1", - "@zowe/zos-jobs-for-zowe-sdk": "8.6.1", - "@zowe/zos-logs-for-zowe-sdk": "8.6.1", - "@zowe/zos-tso-for-zowe-sdk": "8.6.1", - "@zowe/zos-uss-for-zowe-sdk": "8.6.1", - "@zowe/zos-workflows-for-zowe-sdk": "8.6.1", - "@zowe/zosmf-for-zowe-sdk": "8.6.1", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2", + "@zowe/provisioning-for-zowe-sdk": "8.6.2", + "@zowe/zos-console-for-zowe-sdk": "8.6.2", + "@zowe/zos-files-for-zowe-sdk": "8.6.2", + "@zowe/zos-jobs-for-zowe-sdk": "8.6.2", + "@zowe/zos-logs-for-zowe-sdk": "8.6.2", + "@zowe/zos-tso-for-zowe-sdk": "8.6.2", + "@zowe/zos-uss-for-zowe-sdk": "8.6.2", + "@zowe/zos-workflows-for-zowe-sdk": "8.6.2", + "@zowe/zosmf-for-zowe-sdk": "8.6.2", "find-process": "1.4.7", "lodash": "4.17.21", "minimatch": "9.0.5", @@ -78,7 +78,7 @@ "@types/diff": "^5.0.9", "@types/lodash": "^4.17.6", "@types/tar": "^6.1.11", - "@zowe/cli-test-utils": "8.6.1", + "@zowe/cli-test-utils": "8.6.2", "comment-json": "^4.2.3", "strip-ansi": "^6.0.1", "which": "^4.0.0" diff --git a/packages/cli/src/zosfiles/upload/ftu/FileToUSS.handler.ts b/packages/cli/src/zosfiles/upload/ftu/FileToUSS.handler.ts index 654553ee6f..57047f97c4 100644 --- a/packages/cli/src/zosfiles/upload/ftu/FileToUSS.handler.ts +++ b/packages/cli/src/zosfiles/upload/ftu/FileToUSS.handler.ts @@ -37,6 +37,7 @@ export default class FileToUSSHandler extends ZosFilesBaseHandler { const uploadOptions: IUploadOptions = { binary: commandParameters.arguments.binary, + encoding: commandParameters.arguments.encoding, maxConcurrentRequests: commandParameters.arguments.maxConcurrentRequests, task: task, diff --git a/packages/core/package.json b/packages/core/package.json index f577a2df2f..8aa0b92f1b 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/core-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "description": "Core libraries shared by Zowe SDK packages", "author": "Zowe", "license": "EPL-2.0", @@ -49,8 +49,8 @@ "string-width": "^4.2.3" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/imperative": "^8.0.0" diff --git a/packages/imperative/package.json b/packages/imperative/package.json index a0aa2979df..83c53907a8 100644 --- a/packages/imperative/package.json +++ b/packages/imperative/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/imperative", - "version": "8.6.1", + "version": "8.6.2", "description": "framework for building configurable CLIs", "author": "Zowe", "license": "EPL-2.0", diff --git a/packages/imperative/src/cmd/src/doc/ICommandDefinition.ts b/packages/imperative/src/cmd/src/doc/ICommandDefinition.ts index 3d8294934d..8a750b165d 100644 --- a/packages/imperative/src/cmd/src/doc/ICommandDefinition.ts +++ b/packages/imperative/src/cmd/src/doc/ICommandDefinition.ts @@ -14,7 +14,7 @@ import { IChainedHandlerEntry } from "./handler/IChainedHandlerEntry"; import { ICommandOptionDefinition } from "./option/ICommandOptionDefinition"; import { ICommandPositionalDefinition } from "./option/ICommandPositionalDefinition"; import { ICommandDefinitionPassOn } from "./ICommandDefinitionPassOn"; -import { ICommandProfile } from "../../src/doc/profiles/definition/ICommandProfile"; +import { ICommandProfile } from "../doc/profiles/definition/ICommandProfile"; /** * Command Segment type - either "group" or "command". * diff --git a/packages/imperative/src/cmd/src/doc/handler/ICommandHandlerResponseValidator.ts b/packages/imperative/src/cmd/src/doc/handler/ICommandHandlerResponseValidator.ts index 6ec47d051c..581bef3595 100644 --- a/packages/imperative/src/cmd/src/doc/handler/ICommandHandlerResponseValidator.ts +++ b/packages/imperative/src/cmd/src/doc/handler/ICommandHandlerResponseValidator.ts @@ -9,7 +9,7 @@ * */ -import { ICommandResponse } from "../../../src/doc/response/response/ICommandResponse"; +import { ICommandResponse } from "../../doc/response/response/ICommandResponse"; import { CommandResponse } from "../../response/CommandResponse"; export interface ICommandHandlerResponseValidator { diff --git a/packages/imperative/src/cmd/src/doc/response/api/handler/IHandlerFormatOutputApi.ts b/packages/imperative/src/cmd/src/doc/response/api/handler/IHandlerFormatOutputApi.ts index f52555ee6d..4ab25a36e9 100644 --- a/packages/imperative/src/cmd/src/doc/response/api/handler/IHandlerFormatOutputApi.ts +++ b/packages/imperative/src/cmd/src/doc/response/api/handler/IHandlerFormatOutputApi.ts @@ -9,7 +9,7 @@ * */ -import { ICommandOutputFormat } from "../../../../../src/doc/response/response/ICommandOutputFormat"; +import { ICommandOutputFormat } from "../../../../doc/response/response/ICommandOutputFormat"; export interface IHandlerFormatOutputApi { output: (format: ICommandOutputFormat) => void; diff --git a/packages/imperative/src/cmd/src/help/DefaultHelpGenerator.ts b/packages/imperative/src/cmd/src/help/DefaultHelpGenerator.ts index 59387adb23..19d1dd2e1a 100644 --- a/packages/imperative/src/cmd/src/help/DefaultHelpGenerator.ts +++ b/packages/imperative/src/cmd/src/help/DefaultHelpGenerator.ts @@ -17,7 +17,7 @@ import { CommandUtils } from "../utils/CommandUtils"; import { ImperativeError } from "../../../error"; import { IHelpGeneratorParms } from "./doc/IHelpGeneratorParms"; import { IHelpGeneratorFactoryParms } from "./doc/IHelpGeneratorFactoryParms"; -import { compareCommands, ICommandDefinition } from "../../src/doc/ICommandDefinition"; +import { compareCommands, ICommandDefinition } from "../doc/ICommandDefinition"; import stripAnsi = require("strip-ansi"); import { CliUtils } from "../../../utilities/src/CliUtils"; diff --git a/packages/imperative/src/cmd/src/response/CommandResponse.ts b/packages/imperative/src/cmd/src/response/CommandResponse.ts index 17470952f2..62c44037ef 100644 --- a/packages/imperative/src/cmd/src/response/CommandResponse.ts +++ b/packages/imperative/src/cmd/src/response/CommandResponse.ts @@ -24,7 +24,7 @@ import { ImperativeExpect } from "../../../expect"; import { IHandlerFormatOutputApi } from "../doc/response/api/handler/IHandlerFormatOutputApi"; import { ICommandOutputFormat, OUTPUT_FORMAT } from "../doc/response/response/ICommandOutputFormat"; import { Arguments } from "yargs"; -import { ICommandDefinition } from "../../src/doc/ICommandDefinition"; +import { ICommandDefinition } from "../doc/ICommandDefinition"; import { OptionConstants } from "../constants/OptionConstants"; import { inspect } from "util"; import * as DeepMerge from "deepmerge"; diff --git a/packages/imperative/src/cmd/src/yargs/AbstractCommandYargs.ts b/packages/imperative/src/cmd/src/yargs/AbstractCommandYargs.ts index a179f2786b..d0a5381066 100644 --- a/packages/imperative/src/cmd/src/yargs/AbstractCommandYargs.ts +++ b/packages/imperative/src/cmd/src/yargs/AbstractCommandYargs.ts @@ -21,7 +21,7 @@ import { ImperativeYargsCommandAction, IYargsResponse } from "./doc/IYargsRespon import { GroupCommandYargs } from "./GroupCommandYargs"; import { IHelpGeneratorFactory } from "../help/doc/IHelpGeneratorFactory"; import { CommandResponse } from "../response/CommandResponse"; -import { ICommandResponse } from "../../src/doc/response/response/ICommandResponse"; +import { ICommandResponse } from "../doc/response/response/ICommandResponse"; import { ICommandExampleDefinition } from "../.."; import { ImperativeConfig } from "../../../utilities/src/ImperativeConfig"; diff --git a/packages/imperative/src/cmd/src/yargs/CommandYargs.ts b/packages/imperative/src/cmd/src/yargs/CommandYargs.ts index 637e8389d3..3b22542ec0 100644 --- a/packages/imperative/src/cmd/src/yargs/CommandYargs.ts +++ b/packages/imperative/src/cmd/src/yargs/CommandYargs.ts @@ -14,11 +14,11 @@ import { inspect } from "util"; import { Constants } from "../../../constants"; import { IYargsResponse } from "./doc/IYargsResponse"; import { AbstractCommandYargs, YargsCommandCompleted } from "./AbstractCommandYargs"; -import { ICommandOptionDefinition } from "../../src/doc/option/ICommandOptionDefinition"; +import { ICommandOptionDefinition } from "../doc/option/ICommandOptionDefinition"; import { ICommandDefinition } from "../doc/ICommandDefinition"; import { CommandProcessor } from "../CommandProcessor"; -import { ICommandResponse } from "../../src/doc/response/response/ICommandResponse"; -import { CommandResponse } from "../../src/response/CommandResponse"; +import { ICommandResponse } from "../doc/response/response/ICommandResponse"; +import { CommandResponse } from "../response/CommandResponse"; import { ImperativeConfig } from "../../../utilities"; /** diff --git a/packages/imperative/src/cmd/src/yargs/doc/IYargsResponse.ts b/packages/imperative/src/cmd/src/yargs/doc/IYargsResponse.ts index 6d3337007f..97c5b922b5 100644 --- a/packages/imperative/src/cmd/src/yargs/doc/IYargsResponse.ts +++ b/packages/imperative/src/cmd/src/yargs/doc/IYargsResponse.ts @@ -9,7 +9,7 @@ * */ -import { ICommandResponse } from "../../../src/doc/response/response/ICommandResponse"; +import { ICommandResponse } from "../../doc/response/response/ICommandResponse"; /** * Indicates the action performed. */ diff --git a/packages/imperative/src/imperative/src/plugins/PluginManagementFacility.ts b/packages/imperative/src/imperative/src/plugins/PluginManagementFacility.ts index 58094e46a5..bb152f156b 100644 --- a/packages/imperative/src/imperative/src/plugins/PluginManagementFacility.ts +++ b/packages/imperative/src/imperative/src/plugins/PluginManagementFacility.ts @@ -9,8 +9,8 @@ * */ -import { IImperativeConfig } from "../../src/doc/IImperativeConfig"; -import { UpdateImpConfig } from "../../src/UpdateImpConfig"; +import { IImperativeConfig } from "../doc/IImperativeConfig"; +import { UpdateImpConfig } from "../UpdateImpConfig"; import { isAbsolute, join } from "path"; import { ImperativeConfig, JsUtils } from "../../../utilities"; import { Logger } from "../../../logger"; diff --git a/packages/provisioning/package.json b/packages/provisioning/package.json index 5ec3550d6b..3c2653a2c6 100644 --- a/packages/provisioning/package.json +++ b/packages/provisioning/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/provisioning-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "description": "Zowe SDK to interact with the z/OS provisioning APIs", "author": "Zowe", "license": "EPL-2.0", @@ -49,9 +49,9 @@ }, "devDependencies": { "@types/js-yaml": "^4.0.9", - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/core-for-zowe-sdk": "^8.0.0", diff --git a/packages/workflows/package.json b/packages/workflows/package.json index 322a783c6a..cb222f0e41 100644 --- a/packages/workflows/package.json +++ b/packages/workflows/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/zos-workflows-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "description": "Zowe SDK to interact with the z/OS workflows APIs", "author": "Zowe", "license": "EPL-2.0", @@ -45,12 +45,12 @@ "prepack": "node ../../scripts/prepareLicenses.js" }, "dependencies": { - "@zowe/zos-files-for-zowe-sdk": "8.6.1" + "@zowe/zos-files-for-zowe-sdk": "8.6.2" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/core-for-zowe-sdk": "^8.0.0", diff --git a/packages/zosconsole/package.json b/packages/zosconsole/package.json index 2db608eeb1..d6d8de132b 100644 --- a/packages/zosconsole/package.json +++ b/packages/zosconsole/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/zos-console-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "description": "Zowe SDK to interact with the z/OS console", "author": "Zowe", "license": "EPL-2.0", @@ -45,9 +45,9 @@ "prepack": "node ../../scripts/prepareLicenses.js" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/core-for-zowe-sdk": "^8.0.0", diff --git a/packages/zosfiles/CHANGELOG.md b/packages/zosfiles/CHANGELOG.md index 3c53654b69..a7d879d22f 100644 --- a/packages/zosfiles/CHANGELOG.md +++ b/packages/zosfiles/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to the Zowe z/OS files SDK package will be documented in this file. +## `8.6.2` + +- BugFix: Resolved issue where encoding argument was missing from `FileToUss.handler.ts` options object. [#2234](https://github.com/zowe/zowe-cli/pull/2334) +- BugFix: Resolved issue where `FileToUss.handler.ts` options object was not properly passed through subsequent command calls. [#2234](https://github.com/zowe/zowe-cli/pull/2334) + ## `8.4.0` - Enhancement: Added optional `--attributes` flag to `zowe zos-files upload file-to-uss` to allow passing a .zosattributes file path for upload encoding format. [#2319] (https://github.com/zowe/zowe-cli/pull/2319) diff --git a/packages/zosfiles/__tests__/__system__/methods/upload/Upload.system.test.ts b/packages/zosfiles/__tests__/__system__/methods/upload/Upload.system.test.ts index a4c33cfd7e..d9a1e0597e 100644 --- a/packages/zosfiles/__tests__/__system__/methods/upload/Upload.system.test.ts +++ b/packages/zosfiles/__tests__/__system__/methods/upload/Upload.system.test.ts @@ -851,6 +851,7 @@ describe("Upload USS file", () => { let readResponseGood: any; let readResponseBad: any; try { + // Upload file response = runCliScript(__dirname + "/__resources__/upload_file_to_uss.sh", testEnvironment,[ defaultSystem.tso.account, defaultSystem.zosmf.host, @@ -900,6 +901,62 @@ describe("Upload USS file", () => { // Compare file view with not matching upload and view encoding (1047 vs 1147). expect(readResponseBad.stdout.toString()).not.toContain(fileContents); + // Compare file view with matching upload and view encoding (1047). + expect(readResponseGood.stdout.toString()).toContain(fileContents); + }); + it("should upload local file to USS using .zosattributes file - binary", async () => { + let response: any; + let error; + let readResponseGood: any; + let readResponseBad: any; + try { + // Upload file + response = runCliScript(__dirname + "/__resources__/upload_file_to_uss.sh", testEnvironment,[ + defaultSystem.tso.account, + defaultSystem.zosmf.host, + defaultSystem.zosmf.port, + defaultSystem.zosmf.user, + defaultSystem.zosmf.password, + defaultSystem.zosmf.rejectUnauthorized, + __dirname + "/testfiles/encodingCheckBinary.txt", + ussname, + __dirname + "/__resources__/.zosattributes-binary", + ]); + // View file with .txt binary encoding in .zosattributes + readResponseGood = runCliScript(__dirname + "/__resources__/view_file_uss_binary.sh", testEnvironment,[ + defaultSystem.tso.account, + defaultSystem.zosmf.host, + defaultSystem.zosmf.port, + defaultSystem.zosmf.user, + defaultSystem.zosmf.password, + defaultSystem.zosmf.rejectUnauthorized, + ussname, + true + ]); + readResponseBad = runCliScript(__dirname + "/__resources__/view_file_uss.sh", testEnvironment,[ + defaultSystem.tso.account, + defaultSystem.zosmf.host, + defaultSystem.zosmf.port, + defaultSystem.zosmf.user, + defaultSystem.zosmf.password, + defaultSystem.zosmf.rejectUnauthorized, + ussname, + "1047" + ]); + } + catch (err) { + error = err; + Imperative.console.info("Error: " + inspect(error)); + } + const fileContents = fs.readFileSync(__dirname + "/testfiles/encodingCheckBinary.txt").toString(); + + expect(response.stderr.toString()).toBe(""); + expect(response.stdout.toString()).toBeDefined(); + expect(response.stdout.toString()).toContain("USS file uploaded successfully."); + + // Compare file view with not matching upload and view encoding (1047 vs 1147). + expect(readResponseBad.stdout.toString()).not.toContain(fileContents); + // Compare file view with matching upload and view encoding (1047). expect(readResponseGood.stdout.toString()).toContain(fileContents); }); diff --git a/packages/zosfiles/__tests__/__system__/methods/upload/__resources__/.zosattributes-binary b/packages/zosfiles/__tests__/__system__/methods/upload/__resources__/.zosattributes-binary new file mode 100644 index 0000000000..0f79a06bc2 --- /dev/null +++ b/packages/zosfiles/__tests__/__system__/methods/upload/__resources__/.zosattributes-binary @@ -0,0 +1,5 @@ +*.json - +*.bin binary binary +*.jcl IBM-1047 IBM-1047 +*.md UTF-8 UTF-8 +*.txt binary binary \ No newline at end of file diff --git a/packages/zosfiles/__tests__/__system__/methods/upload/__resources__/view_file_uss_binary.sh b/packages/zosfiles/__tests__/__system__/methods/upload/__resources__/view_file_uss_binary.sh new file mode 100755 index 0000000000..3eabe90a6f --- /dev/null +++ b/packages/zosfiles/__tests__/__system__/methods/upload/__resources__/view_file_uss_binary.sh @@ -0,0 +1,12 @@ +#!/bin/bash +account=$1 +host=$2 +port=$3 +user=$4 +password=$5 +ru=$6 +ussName=$7 +encoding=$8 + +zowe zos-files view uf $ussName --binary $binary --host $host --port $port --user $user --password $password --ru $ru +exit $? \ No newline at end of file diff --git a/packages/zosfiles/__tests__/__system__/methods/upload/testfiles/encodingCheck.txt b/packages/zosfiles/__tests__/__system__/methods/upload/testfiles/encodingCheck.txt index ae3e63ebb9..7038873a47 100644 --- a/packages/zosfiles/__tests__/__system__/methods/upload/testfiles/encodingCheck.txt +++ b/packages/zosfiles/__tests__/__system__/methods/upload/testfiles/encodingCheck.txt @@ -1 +1 @@ -á é í ó ú ñ Ç ß 12345 !@#$% ^ [ ] $ £ € \ No newline at end of file +á é í ó ú ñ Ç ß 12345 !@#$% ^ [ ] $ £ \ No newline at end of file diff --git a/packages/zosfiles/__tests__/__system__/methods/upload/testfiles/encodingCheckBinary.txt b/packages/zosfiles/__tests__/__system__/methods/upload/testfiles/encodingCheckBinary.txt new file mode 100644 index 0000000000..385781092d --- /dev/null +++ b/packages/zosfiles/__tests__/__system__/methods/upload/testfiles/encodingCheckBinary.txt @@ -0,0 +1 @@ +[][][] \ No newline at end of file diff --git a/packages/zosfiles/__tests__/__unit__/methods/upload/Upload.unit.test.ts b/packages/zosfiles/__tests__/__unit__/methods/upload/Upload.unit.test.ts index 9f232a790e..7e7e8bf363 100644 --- a/packages/zosfiles/__tests__/__unit__/methods/upload/Upload.unit.test.ts +++ b/packages/zosfiles/__tests__/__unit__/methods/upload/Upload.unit.test.ts @@ -199,7 +199,6 @@ describe("z/OS Files - Upload", () => { expect(error).toBeDefined(); expect(error.message).toContain(ZosFilesMessages.missingDatasetName.message); }); - it("should throw underlying fs error", async () => { const rootError = { code: "test", @@ -226,6 +225,22 @@ describe("z/OS Files - Upload", () => { expect(error.additionalDetails).toEqual(rootError.toString()); expect(error.causeErrors).toBe(rootError); }); + it("should throw error if error is null and stats.isFile() is true", async () => { + const testPath = "test/path"; + lstatSpy.mockImplementationOnce((somePath, callback: any) => { + callback(null, {isFile: () => true}); + }); + + try { + response = await Upload.dirToPds(dummySession, testPath, dsName); + } catch (err) { + error = err; + } + + expect(response).toBeUndefined(); + expect(error).toBeDefined(); + expect(error.message).toContain(ZosFilesMessages.pathIsNotDirectory.message); + }); it("should return with proper message when path is pointing to a file", async () => { lstatSpy.mockImplementationOnce((somePath, callback: any) => { @@ -2475,7 +2490,7 @@ describe("z/OS Files - Upload", () => { expect(fileToUssFileSpy).toHaveBeenCalledTimes(1); expect(fileToUssFileSpy).toHaveBeenCalledWith(dummySession, path.normalize(path.join(testPath, "uploadme")), - `${dsName}/uploadme`, { binary: true }); + `${dsName}/uploadme`, { binary: true, attributes: attributesMock, recursive: false }); }); it("should not upload ignored directories", async () => { @@ -2518,7 +2533,7 @@ describe("z/OS Files - Upload", () => { expect(fileToUssFileSpy).toHaveBeenCalledTimes(1); expect(fileToUssFileSpy).toHaveBeenCalledWith(dummySession, path.normalize(path.join(testPath, "uploaddir", "uploadedfile")), - `${dsName}/uploaddir/uploadedfile`, { binary: true }); + `${dsName}/uploaddir/uploadedfile`, { binary: true, attributes: attributesMock }); }); it("should upload files in text or binary according to attributes", async () => { getFileListFromPathSpy.mockReturnValue(["textfile", "binaryfile"]); @@ -2532,10 +2547,10 @@ describe("z/OS Files - Upload", () => { expect(fileToUssFileSpy).toHaveBeenCalledWith(dummySession, path.normalize(path.join(testPath, "textfile")), `${dsName}/textfile`, - { binary: false, encoding: "ISO8859-1", localEncoding: "ISO8859-1" }); + { binary: false, encoding: "ISO8859-1", localEncoding: "ISO8859-1", attributes: attributesMock, recursive: false }); expect(fileToUssFileSpy).toHaveBeenCalledWith(dummySession, path.normalize(path.join(testPath, "binaryfile")), - `${dsName}/binaryfile`, { binary: true }); + `${dsName}/binaryfile`, { binary: true, recursive: false, attributes: attributesMock }); }); it("should call API to tag files according to remote encoding", async () => { diff --git a/packages/zosfiles/package.json b/packages/zosfiles/package.json index e2b823ff63..54d827f333 100644 --- a/packages/zosfiles/package.json +++ b/packages/zosfiles/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/zos-files-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "description": "Zowe SDK to interact with files and data sets on z/OS", "author": "Zowe", "license": "EPL-2.0", @@ -50,10 +50,10 @@ "minimatch": "^9.0.5" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1", - "@zowe/zos-uss-for-zowe-sdk": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2", + "@zowe/zos-uss-for-zowe-sdk": "8.6.2" }, "peerDependencies": { "@zowe/core-for-zowe-sdk": "^8.0.0", diff --git a/packages/zosfiles/src/methods/upload/Upload.ts b/packages/zosfiles/src/methods/upload/Upload.ts index f13f4eb4bb..13a53abef4 100644 --- a/packages/zosfiles/src/methods/upload/Upload.ts +++ b/packages/zosfiles/src/methods/upload/Upload.ts @@ -854,32 +854,31 @@ export class Upload { }; } - public static async uploadFile(session: AbstractSession, localPath: string, ussPath: string, - options: IUploadOptions): Promise { - const tempOptions: Partial = {}; - + public static async uploadFile( + session: AbstractSession, + localPath: string, + ussPath: string, + options: IUploadOptions + ): Promise { + const tempOptions: IUploadOptions = { ...options }; if (options.attributes) { if (!options.attributes.fileShouldBeUploaded(localPath)) { return; } tempOptions.binary = options.attributes.getFileTransferMode(localPath, options.binary) === TransferMode.BINARY; const remoteEncoding = options.attributes.getRemoteEncoding(localPath); - if (remoteEncoding != null && remoteEncoding !== Tag.BINARY) { - tempOptions.encoding = remoteEncoding; - } + + if(remoteEncoding === Tag.BINARY) tempOptions.encoding = undefined; + else if(remoteEncoding !== null) tempOptions.encoding = remoteEncoding; + if (!tempOptions.binary) { tempOptions.localEncoding = options.attributes.getLocalEncoding(localPath); } - } else { - if (options.filesMap) { - if (options.filesMap.fileNames.indexOf(path.basename(localPath)) > -1) { - tempOptions.binary = options.filesMap.binary; - } else { - tempOptions.binary = options.binary; - } - } else { - tempOptions.binary = options.binary; - } + } else if(options.filesMap?.fileNames.indexOf(path.basename(localPath)) > -1) { + tempOptions.binary = options.filesMap.binary; + + // Reset encoding to undefined if binary is true to avoid file tagging issues + if(tempOptions.binary) tempOptions.encoding = undefined; } return await this.fileToUssFile(session, localPath, ussPath, tempOptions); diff --git a/packages/zosjobs/package.json b/packages/zosjobs/package.json index dd7660d7dd..fdc5156464 100644 --- a/packages/zosjobs/package.json +++ b/packages/zosjobs/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/zos-jobs-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "description": "Zowe SDK to interact with jobs on z/OS", "author": "Zowe", "license": "EPL-2.0", @@ -46,12 +46,12 @@ "prepack": "node ../../scripts/prepareLicenses.js" }, "dependencies": { - "@zowe/zos-files-for-zowe-sdk": "8.6.1" + "@zowe/zos-files-for-zowe-sdk": "8.6.2" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/core-for-zowe-sdk": "^8.0.0", diff --git a/packages/zoslogs/package.json b/packages/zoslogs/package.json index 112c0bc7cb..c7fdaca2ef 100644 --- a/packages/zoslogs/package.json +++ b/packages/zoslogs/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/zos-logs-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "description": "Zowe SDK to interact with the z/OS logs", "author": "Zowe", "license": "EPL-2.0", @@ -45,9 +45,9 @@ "prepack": "node ../../scripts/prepareLicenses.js" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/core-for-zowe-sdk": "^8.0.0", diff --git a/packages/zosmf/package.json b/packages/zosmf/package.json index ef2644bfa6..5c84b13d8c 100644 --- a/packages/zosmf/package.json +++ b/packages/zosmf/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/zosmf-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "description": "Zowe SDK to interact with the z/OS Management Facility", "author": "Zowe", "license": "EPL-2.0", @@ -44,9 +44,9 @@ "prepack": "node ../../scripts/prepareLicenses.js" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/core-for-zowe-sdk": "^8.0.0", diff --git a/packages/zostso/CHANGELOG.md b/packages/zostso/CHANGELOG.md index 63188b9bea..25f79e7a01 100644 --- a/packages/zostso/CHANGELOG.md +++ b/packages/zostso/CHANGELOG.md @@ -2,6 +2,10 @@ All notable changes to the Zowe z/OS TSO SDK package will be documented in this file. +## `8.6.2` + +- BugFix: Fixed imports that failed to resolve. [#2343](https://github.com/zowe/zowe-cli/pull/2343) + ## `8.6.0` - Enhancement: Issue `app` commands to better target communication with a TSO/E application. The `app` command is now included in the `start`/`send` command group and the new `receive` command group, diff --git a/packages/zostso/package.json b/packages/zostso/package.json index 66013cb01c..233434a46e 100644 --- a/packages/zostso/package.json +++ b/packages/zostso/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/zos-tso-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "description": "Zowe SDK to interact with TSO on z/OS", "author": "Zowe", "license": "EPL-2.0", @@ -45,12 +45,12 @@ "prepack": "node ../../scripts/prepareLicenses.js" }, "dependencies": { - "@zowe/zosmf-for-zowe-sdk": "8.6.1" + "@zowe/zosmf-for-zowe-sdk": "8.6.2" }, "devDependencies": { - "@zowe/cli-test-utils": "8.6.1", - "@zowe/core-for-zowe-sdk": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/core-for-zowe-sdk": "8.6.2", + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/core-for-zowe-sdk": "^8.0.0", diff --git a/packages/zostso/src/AddressSpaceApps.ts b/packages/zostso/src/AddressSpaceApps.ts index 3169d464c2..b79a93d8b9 100644 --- a/packages/zostso/src/AddressSpaceApps.ts +++ b/packages/zostso/src/AddressSpaceApps.ts @@ -18,7 +18,7 @@ import { IStartTsoParms } from "./doc/input/IStartTsoParms"; import { TsoValidator } from "./TsoValidator"; import { IStartTsoAppParms } from "./doc/input/IStartTsoAppParms"; import { StartTso } from "./StartTso"; -import { IIssueResponse } from "../src"; +import { IIssueResponse } from "./doc/IIssueResponse"; export class AddressSpaceApps { /** diff --git a/packages/zostso/src/doc/IASAppResponse.ts b/packages/zostso/src/doc/IASAppResponse.ts index 5b43b31526..d9afd33f2f 100644 --- a/packages/zostso/src/doc/IASAppResponse.ts +++ b/packages/zostso/src/doc/IASAppResponse.ts @@ -9,7 +9,7 @@ * */ -import { ITsoMessage } from "../../src"; +import { ITsoMessage } from "./zosmf/ITsoMessage"; export interface IASAppResponse { /** diff --git a/packages/zostso/src/doc/IIssueResponse.ts b/packages/zostso/src/doc/IIssueResponse.ts index b54ab48062..6d40d95287 100644 --- a/packages/zostso/src/doc/IIssueResponse.ts +++ b/packages/zostso/src/doc/IIssueResponse.ts @@ -33,7 +33,7 @@ export interface IIssueResponse { startResponse?: IStartStopResponses; /** - * Indicates if started TSO containes "READY " message + * Indicates if started TSO contains "READY" message * @type {boolean} * @memberof IIssueResponse */ diff --git a/packages/zosuss/package.json b/packages/zosuss/package.json index c6a33495e4..4e5ebb3190 100644 --- a/packages/zosuss/package.json +++ b/packages/zosuss/package.json @@ -1,6 +1,6 @@ { "name": "@zowe/zos-uss-for-zowe-sdk", - "version": "8.6.1", + "version": "8.6.2", "description": "Zowe SDK to interact with USS on z/OS", "author": "Zowe", "license": "EPL-2.0", @@ -49,8 +49,8 @@ }, "devDependencies": { "@types/ssh2": "^1.11.19", - "@zowe/cli-test-utils": "8.6.1", - "@zowe/imperative": "8.6.1" + "@zowe/cli-test-utils": "8.6.2", + "@zowe/imperative": "8.6.2" }, "peerDependencies": { "@zowe/imperative": "^8.0.0"