Skip to content

Commit

Permalink
Merge commit 'b2c62f4' into chore/update-with-2.13.0
Browse files Browse the repository at this point in the history
Signed-off-by: Billie Simmons <[email protected]>
  • Loading branch information
JillieBeanSim committed Dec 12, 2023
2 parents 5af44d9 + b2c62f4 commit 9507742
Show file tree
Hide file tree
Showing 70 changed files with 1,526 additions and 636 deletions.
13 changes: 0 additions & 13 deletions CODEOWNERS

This file was deleted.

6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,3 +101,9 @@ For more information on how to contribute, see [Contributor Guidance](https://gi
## External Links

Check out more about using Zowe Explorer and Zowe on [Medium](https://medium.com/zowe) and [Awesome Zowe](https://github.com/tucker01/awesome-zowe).

## Project Structure and Governance

Zowe Explorer is a component of the Zowe Open Mainframe Project, part of the Linux Foundation.

To learn more about how Zowe is structured and governed, see the [Technical Steering Committee Strucutre and Governance documentation](https://github.com/zowe/community/blob/master/Technical-Steering-Committee/tsc-governance.md).
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "2.12.3-SNAPSHOT",
"version": "2.14.1-SNAPSHOT",
"command": {
"version": {
"forcePublish": true,
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"vscode": "^1.53.2"
},
"dependencies": {
"@zowe/cli": "7.18.0",
"@zowe/cli": "7.19.0",
"vscode-nls": "4.1.2"
},
"devDependencies": {
Expand Down
2 changes: 2 additions & 0 deletions packages/eslint-plugin-zowe-explorer/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ All notable changes to the "eslint-plugin-zowe-explorer" package will be documen

### Bug fixes

## `2.13.0`

## `2.12.2`

## `2.12.1`
Expand Down
2 changes: 1 addition & 1 deletion packages/eslint-plugin-zowe-explorer/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "eslint-plugin-zowe-explorer",
"version": "2.12.3-SNAPSHOT",
"version": "2.14.1-SNAPSHOT",
"description": "Custom ESLint Rules for ZOWE Explorer",
"keywords": [
"eslint",
Expand Down
9 changes: 9 additions & 0 deletions packages/zowe-explorer-api/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,15 @@ All notable changes to the "zowe-explorer-api" extension will be documented in t

### Bug fixes

## `2.13.0`

### New features and enhancements

- Added new optional boolean parameter `hideFromAllTrees` to `IZoweTree.deleteSession` for specifying whether to hide from all trees or current tree. [#2567](https://github.com/zowe/vscode-extension-for-zowe/issues/2567)
- Added new optional parameter `provider` of type `IZoweTree<IZoweTreeNode>` for `IZoweTree.addSession` to specify a tree to add the profile to.
- Added optional `filter` and `actualJobs` variables to `IZoweJobTreeNode` to track local filter search.
- Added new optional record `openFiles` to `IZoweTree` to track opened files under a specific tree view. [#2597](https://github.com/zowe/vscode-extension-for-zowe/issues/2597)

## `2.12.2`

## `2.12.1`
Expand Down
6 changes: 3 additions & 3 deletions packages/zowe-explorer-api/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@zowe/zowe-explorer-api",
"version": "2.12.3-SNAPSHOT",
"version": "2.14.1-SNAPSHOT",
"description": "Extensibility API for Zowe Explorer.",
"publisher": "Zowe",
"author": "Zowe",
Expand All @@ -18,8 +18,8 @@
},
"dependencies": {
"@types/vscode": "^1.53.2",
"@zowe/cli": "^7.18.0",
"@zowe/secrets-for-zowe-sdk": "7.18.4",
"@zowe/cli": "7.19.0",
"@zowe/secrets-for-zowe-sdk": "7.18.6",
"handlebars": "^4.7.7",
"semver": "^7.5.3"
},
Expand Down
29 changes: 27 additions & 2 deletions packages/zowe-explorer-api/src/tree/IZoweTree.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
*/

import * as vscode from "vscode";
import { imperative } from "@zowe/cli";
import { IZoweTreeNode } from "./IZoweTreeNode";
import { DataSetAllocTemplate, PersistenceSchemaEnum } from "../profiles/UserSettings";

Expand Down Expand Up @@ -59,18 +60,36 @@ export interface IZoweTree<T> extends vscode.TreeDataProvider<T> {
*/
copying?: Promise<unknown>;

/**
* A record of open files from this tree.
*/
openFiles?: Record<string, IZoweTreeNode>;

/**
* Adds a session to the container
* @param sessionName
* @param type e.g. zosmf
* @param provider tree provider to add to, undefined will add for all
*/
addSession(sessionName?: string, type?: string, provider?: IZoweTree<IZoweTreeNode>): Promise<void>;

/**
* Adds a single session to the tree
* @param profile the profile to add to the tree
*/
addSession(sessionName?: string, type?: string): Promise<void>;
addSingleSession(profile: imperative.IProfileLoaded): Promise<void>;

/**
* Edit a session to the container
* @param node This parameter identifies the node that needs to be called
*/
editSession(node: IZoweTreeNode, zoweFileProvider: IZoweTree<IZoweTreeNode>): Promise<void>;

/**
* Get sessions from persistent object of provider
*/
getSessions(): string[];

/**
* Add a new session to the container
* @param zoweFileProvider The tree to which the profile should be added
Expand Down Expand Up @@ -206,8 +225,9 @@ export interface IZoweTree<T> extends vscode.TreeDataProvider<T> {
/**
* Deletes a root node from the tree.
* @param node: A root node representing a session
* @param hideFromAllTrees: <optional> whether to hide from all trees or just the single tree
*/
deleteSession(node: IZoweTreeNode);
deleteSession(node: IZoweTreeNode, hideFromAllTrees?: boolean);
/**
* Lets the user open a dataset by filtering the currently-loaded list
*/
Expand Down Expand Up @@ -268,6 +288,11 @@ export interface IZoweTree<T> extends vscode.TreeDataProvider<T> {
* @param {string} name the member to remove
*/
removeFileHistory?(name: string);
/**
* Removes session from the session array
* @param {string} name the sessions to remove
*/
removeSession?(name: string): void;
/**
* Returns a new dataset filter string, from an old filter and a new string
*
Expand Down
8 changes: 8 additions & 0 deletions packages/zowe-explorer-api/src/tree/IZoweTreeNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,14 @@ export interface IZoweJobTreeNode extends IZoweTreeNode {
* Returns whether the job node is a filtered search
*/
filtered?: boolean;
/**
* Filter method for this job search
*/
filter?: string;
/**
* Array of original filter search results job's children
*/
actualJobs?: IZoweTreeNode[];
/**
* Retrieves child nodes of this IZoweJobTreeNode
*
Expand Down
2 changes: 2 additions & 0 deletions packages/zowe-explorer-ftp-extension/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ All notable changes to the "zowe-explorer-ftp-extension" extension will be docum

### Bug fixes

## `2.13.0`

## `2.12.2`

## `2.12.1`
Expand Down
4 changes: 2 additions & 2 deletions packages/zowe-explorer-ftp-extension/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"author": "Zowe",
"license": "EPL-2.0",
"description": "Adds zFTP support to Zowe Explorer demonstrating how to extend the Zowe Explorer using its extensibility API.",
"version": "2.12.3-SNAPSHOT",
"version": "2.14.1-SNAPSHOT",
"icon": "resources/zowe-ftp-color.png",
"repository": {
"url": "https://github.com/zowe/vscode-extension-for-zowe"
Expand Down Expand Up @@ -48,7 +48,7 @@
},
"dependencies": {
"@zowe/zos-ftp-for-zowe-cli": "2.1.2",
"@zowe/zowe-explorer-api": "2.12.3-SNAPSHOT",
"@zowe/zowe-explorer-api": "2.14.1-SNAPSHOT",
"tmp": "0.2.1"
},
"devDependencies": {
Expand Down
16 changes: 15 additions & 1 deletion packages/zowe-explorer/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,21 @@ All notable changes to the "vscode-extension-for-zowe" extension will be documen

### Bug fixes

## `2.13.0`

### New features and enhancements

- Added support for hiding a Zowe profile across all trees [#2567](https://github.com/zowe/vscode-extension-for-zowe/issues/2567)
- Added support for enabling/disabling validation for a Zowe profile across all trees [#2570](https://github.com/zowe/vscode-extension-for-zowe/issues/2570)
- Added Display confirmation dialog when submitting local JCL. [#2061](https://github.com/zowe/vscode-extension-for-zowe/issues/2061)
- Added support for adding a Zowe profile across all trees [#2603](https://github.com/zowe/vscode-extension-for-zowe/issues/2603)
- Added "Filter Jobs" feature in Jobs tree view: accessible via filter icon or right-clicking on session node. [#2599](https://github.com/zowe/vscode-extension-for-zowe/issues/2599)

### Bug fixes

- Fixed dataset allocation issue when secondary space (or other numeric values that did not exists in the dataset-template) where specified [#2591](https://github.com/zowe/vscode-extension-for-zowe/issues/2591)
- Fixed issue where an opened USS file or data set could not be saved once a user changes their search pattern in the Side Bar. [#2597](https://github.com/zowe/vscode-extension-for-zowe/issues/2597)

## `2.12.2`

### Bug fixes
Expand All @@ -30,7 +45,6 @@ All notable changes to the "vscode-extension-for-zowe" extension will be documen

### New features and enhancements

- Added "Sort Jobs" feature in Jobs tree view: accessible via sort icon or right-clicking on session node. [#2257](https://github.com/zowe/vscode-extension-for-zowe/issues/2257)
- Introduce a new user interface for managing profiles via right-click action "Manage Profile".
- Added new edit feature on `Edit Attributes` view for changing file tags on USS. [#2113](https://github.com/zowe/vscode-extension-for-zowe/issues/2113)
- Added new API {ZE Extender MetaData} to allow extenders to have the metadata of registered extenders to aid in team configuration file creation from a view that isn't Zowe Explorer's. [#2394](https://github.com/zowe/vscode-extension-for-zowe/issues/2394)
Expand Down
1 change: 1 addition & 0 deletions packages/zowe-explorer/__mocks__/mockCreators/jobs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ export function createJobsTree(session: imperative.Session, iJob: IJob, profile:
getSession: jest.fn(),
delete: jest.fn(),
setItem: jest.fn(),
openFiles: {},
};
testJobsTree.mSessionNodes = [];
testJobsTree.mSessionNodes.push(jobNode);
Expand Down
71 changes: 68 additions & 3 deletions packages/zowe-explorer/__mocks__/mockCreators/shared.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,11 @@ import { ZoweTreeProvider } from "../../src/abstract/ZoweTreeProvider";
import { ZoweDatasetNode } from "../../src/dataset/ZoweDatasetNode";
import { ZoweUSSNode } from "../../src/uss/ZoweUSSNode";
import * as vscode from "vscode";
import { ValidProfileEnum } from "@zowe/zowe-explorer-api";
import { ValidProfileEnum, IZoweTreeNode } from "@zowe/zowe-explorer-api";
import { FilterDescriptor } from "../../src/utils/ProfilesUtils";
import { imperative, ZosmfSession } from "@zowe/cli";
import { SettingsConfig } from "../../src/utils/SettingsConfig";
import * as globals from "../../src/globals";

export function createPersistentConfig() {
return {
Expand Down Expand Up @@ -280,13 +281,15 @@ export function createTreeView(selection?): vscode.TreeView<ZoweTreeProvider> {
visible: true,
onDidChangeVisibility: jest.fn(),
dispose: jest.fn(),
addSingleSession: jest.fn(),
} as unknown as vscode.TreeView<ZoweTreeProvider>;
}

export function createTextDocument(name: string, sessionNode?: ZoweDatasetNode | ZoweUSSNode): vscode.TextDocument {
const fileName = sessionNode ? `/${sessionNode.label}/${name}` : name;
return {
fileName: sessionNode ? `/${sessionNode.label}/${name}` : name,
uri: null,
fileName,
uri: vscode.Uri.parse(fileName),
isUntitled: null,
languageId: null,
version: null,
Expand Down Expand Up @@ -548,3 +551,65 @@ export function createOutputChannel() {
replace: jest.fn(),
} as vscode.OutputChannel;
}

export function createMockNode(name: string, context: string): IZoweTreeNode {
return {
dirty: false,
getLabel: jest.fn(() => name),
getChildren: jest.fn(),
getParent: jest.fn(),
getProfile: jest.fn(() => ({
name,
profile: {
host: "fake",
port: 999,
rejectUnauthorize: false,
},
type: "zosmf",
message: "",
failNotFound: false,
})),
getProfileName: jest.fn(),
getSession: jest.fn(),
getSessionNode: jest.fn(),
setProfileToChoice: jest.fn(),
setSessionToChoice: jest.fn(),
label: name,
contextValue: context,
};
}

export function createTreeProviders() {
return {
ds: {
mSessionNodes: [
createMockNode("zosmf", globals.DS_SESSION_CONTEXT + globals.VALIDATE_SUFFIX),
createMockNode("zosmf2", globals.DS_SESSION_CONTEXT + globals.NO_VALIDATE_SUFFIX),
],
deleteSession: jest.fn(),
removeSession: jest.fn(),
refresh: jest.fn(),
addSingleSession: jest.fn(),
} as any,
uss: {
mSessionNodes: [
createMockNode("zosmf", globals.USS_SESSION_CONTEXT + globals.VALIDATE_SUFFIX),
createMockNode("zosmf2", globals.USS_SESSION_CONTEXT + globals.NO_VALIDATE_SUFFIX),
],
deleteSession: jest.fn(),
removeSession: jest.fn(),
refresh: jest.fn(),
addSingleSession: jest.fn(),
} as any,
job: {
mSessionNodes: [
createMockNode("zosmf", globals.JOBS_SESSION_CONTEXT + globals.VALIDATE_SUFFIX),
createMockNode("zosmf2", globals.JOBS_SESSION_CONTEXT + globals.NO_VALIDATE_SUFFIX),
],
removeSession: jest.fn(),
deleteSession: jest.fn(),
refresh: jest.fn(),
addSingleSession: jest.fn(),
} as any,
};
}
5 changes: 5 additions & 0 deletions packages/zowe-explorer/__mocks__/vscode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,10 @@ export namespace window {
return Promise.resolve("");
}

export function showTextDocument(document: TextDocument, column?: ViewColumn, preserveFocus?: boolean): any {
return undefined;
}

export function showErrorMessage(message: string, ...items: string[]): undefined {
return undefined;
}
Expand Down Expand Up @@ -584,6 +588,7 @@ export class EventEmitter<T> {
*/
export namespace workspace {
export function onDidSaveTextDocument<T>(listener: (e: T) => any, thisArgs?: any, disposables?: Disposable[]) {}
export function onDidCloseTextDocument<T>(listener: (e: T) => any, thisArgs?: any, disposables?: Disposable[]) {}

export function getConfiguration(configuration: string) {
return {
Expand Down
Loading

0 comments on commit 9507742

Please sign in to comment.