Skip to content

Commit

Permalink
Merge pull request #2432 from zowe/update/maintenance-2.10.0
Browse files Browse the repository at this point in the history
Update maintenance with 2.10.0
  • Loading branch information
t1m0thyj authored Aug 28, 2023
2 parents 42ad3df + 633a0e6 commit 4837219
Show file tree
Hide file tree
Showing 105 changed files with 6,409 additions and 515 deletions.
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@ lib
logs
testProfileData.ts
results
debug.log
*.log
npm-shrinkwrap.json
vscode-extension-for-zowe*.vsix
.vscode/settings.json
.vscode/*.env
.vscode-test
.history
.DS_Store
Expand All @@ -19,3 +20,5 @@ temp
*.tgz
.tmp
coverage/
dist/
prebuilds/
3 changes: 2 additions & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
"outFiles": ["${workspaceFolder}/packages/zowe-explorer/out/**/*.js"],
"preLaunchTask": "build dev watch",
"smartStep": true,
"skipFiles": ["<node_internals>/**"]
"skipFiles": ["<node_internals>/**"],
"envFile": "${workspaceFolder}/.vscode/.env"
},
{
// TODO: This launch-configuration should be updated to run the Theia container locally
Expand Down
6 changes: 6 additions & 0 deletions .vscode/sample_env
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Create a ".env" file with the contents of this file

# Make sure to get a valid DBus Session Address
# by unlocking the keyring on a terminal, and
# copy the contents of "echo $DBUS_SESSION_BUS_ADDRESS"
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/0/bus
3 changes: 2 additions & 1 deletion .yarnrc
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
registry: "https://registry.npmjs.org/"
registry: "https://registry.npmjs.org/"
"@zowe:registry" "https://zowe.jfrog.io/zowe/api/npm/npm-local-release/"
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Join our [Slack channel](https://slack.openmainframeproject.org/) to connect wit
Client-side prerequisites for development:

- Install [Node.js](https://nodejs.org/en/download/) v14.0 or later.
- Install [Yarn](https://yarnpkg.com/getting-started/install).
- Install [Yarn](https://classic.yarnpkg.com) Classic.

Host-side prerequisites for connection:

Expand Down
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "2.9.3-SNAPSHOT",
"version": "2.10.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 @@ -15,7 +15,7 @@
"vscode": "^1.53.2"
},
"dependencies": {
"@zowe/cli": "7.16.6",
"@zowe/cli": "7.18.0",
"vscode-nls": "4.1.2"
},
"devDependencies": {
Expand Down
6 changes: 6 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,12 @@ All notable changes to the "eslint-plugin-zowe-explorer" package will be documen

### Bug fixes

## `2.10.0`

### New features and enhancements

### Bug fixes

## `2.9.2`

### New features and enhancements
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.9.3-SNAPSHOT",
"version": "2.10.1-SNAPSHOT",
"description": "Custom ESLint Rules for ZOWE Explorer",
"keywords": [
"eslint",
Expand Down
9 changes: 9 additions & 0 deletions packages/samples/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Zowe Explorer Sample Packages

This folder contains sample packages for reference during development, for both Zowe Explorer contributors and extender developers.

---

## vue-webview-sample

Demonstrates the use of the `WebView` class from Zowe Explorer API to create a webview panel, powered by the Vite bundler and Vue JavaScript framework.
18 changes: 18 additions & 0 deletions packages/samples/vue-webview-sample/.vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
// A launch configuration that compiles the extension and then opens it inside a new window
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
{
"version": "0.2.0",
"configurations": [
{
"name": "Run Extension",
"type": "extensionHost",
"request": "launch",
"runtimeExecutable": "${execPath}",
"args": ["--extensionDevelopmentPath=${workspaceFolder}"],
"outFiles": ["${workspaceFolder}/out/**/*.js"],
"preLaunchTask": "npm: watch"
}
]
}
20 changes: 20 additions & 0 deletions packages/samples/vue-webview-sample/.vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
{
"version": "2.0.0",
"tasks": [
{
"type": "npm",
"script": "watch",
"problemMatcher": "$tsc-watch",
"isBackground": true,
"presentation": {
"reveal": "never"
},
"group": {
"kind": "build",
"isDefault": true
}
}
]
}
40 changes: 40 additions & 0 deletions packages/samples/vue-webview-sample/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"name": "vue-webview-sample",
"displayName": "vue-webview-sample",
"description": "Sample VSCode extension leveraging ZE API WebView class and a Vite-powered Vue demo",
"private": true,
"version": "0.0.1",
"engines": {
"vscode": "^1.74.0"
},
"categories": [
"Other"
],
"activationEvents": [],
"main": "./out/extension.js",
"contributes": {
"commands": [
{
"command": "extension.helloWorld",
"title": "Hello World"
}
]
},
"scripts": {
"vscode:prepublish": "yarn build",
"build": "npx tsc -p ./ && cd webviews/vue-sample && yarn && yarn build",
"lint": "eslint \"src/**/*.ts\"",
"watch": "npx tsc -watch -p ./"
},
"dependencies": {
"@zowe/zowe-explorer-api": "file:../../zowe-explorer-api"
},
"devDependencies": {
"@types/node": "^16.18.41",
"@types/vscode": "^1.53.2",
"@typescript-eslint/eslint-plugin": "^5.42.0",
"@typescript-eslint/parser": "^5.42.0",
"eslint": "^8.26.0",
"vue-tsc": "^1.8.8"
}
}
14 changes: 14 additions & 0 deletions packages/samples/vue-webview-sample/src/extension.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import * as vscode from "vscode";
import { WebView } from "@zowe/zowe-explorer-api";

export function activate(context: vscode.ExtensionContext) {
console.log('Congratulations, your extension "helloworld-sample" is now active!');

const disposable = vscode.commands.registerCommand("extension.helloWorld", () => {
const webview = new WebView("Sample Webview", "vue-sample", context, (message: Record<string, any>) => {
vscode.window.showInformationMessage(message.text);
});
});

context.subscriptions.push(disposable);
}
13 changes: 13 additions & 0 deletions packages/samples/vue-webview-sample/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"compilerOptions": {
"module": "commonjs",
"target": "es2020",
"lib": ["es2020"],
"outDir": "out",
"skipLibCheck": true,
"sourceMap": true,
"strict": true,
"rootDir": "src"
},
"exclude": ["node_modules", ".vscode-test", "webviews"]
}
12 changes: 12 additions & 0 deletions packages/samples/vue-webview-sample/webviews/vue-sample/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Vite + Vue + TS</title>
</head>
<body>
<div id="app"></div>
<script type="module" src="/src/main.ts"></script>
</body>
</html>
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"name": "vue-sample",
"private": true,
"version": "0.0.0",
"type": "module",
"scripts": {
"dev": "vite",
"build": "vue-tsc && vite build",
"preview": "vite preview"
},
"dependencies": {
"@types/vscode-webview": "^1.57.1",
"vue": "^3.3.4"
},
"devDependencies": {
"@vitejs/plugin-vue": "^4.2.3",
"typescript": "^5.0.2",
"vite": "^4.4.9",
"vue-tsc": "^1.8.8"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<script setup lang="ts">
import HelloWorld from "./components/HelloWorld.vue";
</script>

<template>
<HelloWorld msg="Vite + Vue + Zowe" />
</template>
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<script setup lang="ts">
// @ts-nocheck
declare let acquireVsCodeApi: Function;
defineProps<{ msg: string }>();
const vscodeApi = acquireVsCodeApi();
function sendMsg() {
// .value is needed in JavaScript
vscodeApi.postMessage({
text: "Hello from Vue!",
});
}
</script>

<template>
<h1>{{ msg }}</h1>

<div class="card">
<button type="button" @click="sendMsg">Send message to ZE</button>
</div>
</template>
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import { createApp } from "vue";
import "./style.css";
import App from "./App.vue";

createApp(App).mount("#webviewRoot");
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
:root {
font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
line-height: 1.5;
font-weight: 400;

color-scheme: light dark;
color: rgba(255, 255, 255, 0.87);
background-color: #242424;

font-synthesis: none;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
-webkit-text-size-adjust: 100%;
}

a {
font-weight: 500;
color: #646cff;
text-decoration: inherit;
}
a:hover {
color: #535bf2;
}

body {
margin: 0;
display: flex;
place-items: center;
min-width: 320px;
min-height: 100vh;
}

h1 {
font-size: 3.2em;
line-height: 1.1;
}

button {
border-radius: 8px;
border: 1px solid transparent;
padding: 0.6em 1.2em;
font-size: 1em;
font-weight: 500;
font-family: inherit;
background-color: #1a1a1a;
cursor: pointer;
transition: border-color 0.25s;
}
button:hover {
border-color: #646cff;
}
button:focus,
button:focus-visible {
outline: 4px auto -webkit-focus-ring-color;
}

.card {
padding: 2em;
}

#app {
max-width: 1280px;
margin: 0 auto;
padding: 2rem;
text-align: center;
}

@media (prefers-color-scheme: light) {
:root {
color: #213547;
background-color: #ffffff;
}
a:hover {
color: #747bff;
}
button {
background-color: #f9f9f9;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/// <reference types="vite/client" />
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"compilerOptions": {
"target": "ES2020",
"useDefineForClassFields": true,
"module": "ESNext",
"lib": ["ES2020", "DOM", "DOM.Iterable"],
"skipLibCheck": true,

/* Bundler mode */
"moduleResolution": "node",
"allowImportingTsExtensions": true,
"resolveJsonModule": true,
"isolatedModules": true,
"noEmit": true,
"jsx": "preserve",

/* Linting */
"strict": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"noFallthroughCasesInSwitch": true
},
"include": ["src/**/*.ts", "src/**/*.d.ts", "src/**/*.tsx", "src/**/*.vue"],
"references": [{ "path": "./tsconfig.node.json" }]
}
Loading

0 comments on commit 4837219

Please sign in to comment.