Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change from opn (deprecated) to open #867

Merged
merged 8 commits into from
Mar 29, 2021
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 5 additions & 23 deletions ui/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions ui/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "vscode-azureextensionui",
"author": "Microsoft Corporation",
"version": "0.40.0",
"version": "0.40.1",
"description": "Common UI tools for developing Azure extensions for VS Code",
"tags": [
"azure",
Expand Down Expand Up @@ -40,7 +40,6 @@
"escape-string-regexp": "^2.0.0",
"fs-extra": "^8.0.0",
"html-to-text": "^5.1.1",
"opn": "^6.0.0",
"semver": "^5.7.1",
"vscode-extension-telemetry": "^0.1.5",
"vscode-nls": "^4.1.1",
Expand Down
9 changes: 2 additions & 7 deletions ui/src/utils/openUrl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,8 @@
* Licensed under the MIT License. See License.md in the project root for license information.
*--------------------------------------------------------------------------------------------*/

// tslint:disable-next-line:no-require-imports
import opn = require("opn");
import * as vscode from 'vscode';

export async function openUrl(url: string): Promise<void> {
// Using this functionality is blocked by https://github.com/Microsoft/vscode/issues/25852:
// await vscode.commands.executeCommand('vscode.open', vscode.Uri.parse(url));

// tslint:disable-next-line: no-unsafe-any
opn(url);
bwateratmsft marked this conversation as resolved.
Show resolved Hide resolved
await vscode.env.openExternal(vscode.Uri.parse(url));
bwateratmsft marked this conversation as resolved.
Show resolved Hide resolved
}