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

copy-paste -> clipboardy #256

Merged
merged 4 commits into from Dec 7, 2018
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
229 changes: 155 additions & 74 deletions package-lock.json

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions package.json
Expand Up @@ -662,7 +662,6 @@
"all": "npm i && npm run lint && npm test"
},
"devDependencies": {
"@types/copy-paste": "^1.1.30",
"@types/fs-extra": "=5.0.2",
"@types/glob": "^5.0.35",
"@types/mocha": "^5.2.5",
Expand All @@ -685,10 +684,11 @@
"ms-vscode.azure-account"
],
"dependencies": {
"@types/clipboardy": "^1.1.0",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be a dev dependency

"azure-arm-resource": "^3.1.1-preview",
"azure-arm-storage": "^5.1.1-preview",
"azure-storage": "^2.10.0",
"copy-paste": "^1.3.0",
"clipboardy": "^1.2.3",
"fs-extra": "^4.0.2",
"glob": "^7.1.2",
"ms-rest": "^2.2.2",
Expand Down
Expand Up @@ -4,12 +4,12 @@
*--------------------------------------------------------------------------------------------*/

import * as azureStorage from "azure-storage";
import * as copypaste from 'copy-paste';
import * as clipboardy from 'clipboardy';
import * as fse from 'fs-extra';
import * as glob from 'glob';
import * as path from 'path';
import { ProgressLocation, Uri } from 'vscode';
import * as vscode from 'vscode';
import { ProgressLocation, Uri } from 'vscode';
import { AzureParentTreeItem, AzureTreeItem, DialogResponses, IActionContext, parseError, TelemetryProperties, UserCancelledError } from 'vscode-azureextensionui';
import { awaitWithProgress } from '../../components/progress';
import { ext } from "../../extensionVariables";
Expand Down Expand Up @@ -132,7 +132,7 @@ export class BlobContainerTreeItem extends AzureParentTreeItem<IStorageRoot> imp
public async copyUrl(): Promise<void> {
let blobService = this.root.createBlobService();
let url = blobService.getUrl(this.container.name);
copypaste.copy(url);
clipboardy.write(url);
ext.outputChannel.show();
ext.outputChannel.appendLine(`Container URL copied to clipboard: ${url}`);
}
Expand Down
4 changes: 2 additions & 2 deletions src/azureStorageExplorer/blobContainers/blobNode.ts
Expand Up @@ -4,7 +4,7 @@
**/

import * as azureStorage from "azure-storage";
import * as copypaste from 'copy-paste';
import * as clipboardy from 'clipboardy';
import * as path from 'path';
import { SaveDialogOptions, Uri, window } from 'vscode';
import { AzureParentTreeItem, AzureTreeItem, DialogResponses, UserCancelledError } from 'vscode-azureextensionui';
Expand Down Expand Up @@ -33,7 +33,7 @@ export class BlobTreeItem extends AzureTreeItem<IStorageRoot> implements ICopyUr
public async copyUrl(): Promise<void> {
let blobService = this.root.createBlobService();
let url = blobService.getUrl(this.container.name, this.blob.name);
copypaste.copy(url);
clipboardy.write(url);
ext.outputChannel.show();
ext.outputChannel.appendLine(`Blob URL copied to clipboard: ${url}`);
}
Expand Down
4 changes: 2 additions & 2 deletions src/azureStorageExplorer/fileShares/directoryNode.ts
Expand Up @@ -4,7 +4,7 @@
*--------------------------------------------------------------------------------------------*/

import * as azureStorage from "azure-storage";
import * as copypaste from 'copy-paste';
import * as clipboardy from 'clipboardy';
import * as path from 'path';
import { Uri, window } from 'vscode';
import { AzureParentTreeItem, DialogResponses, UserCancelledError } from 'vscode-azureextensionui';
Expand Down Expand Up @@ -63,7 +63,7 @@ export class DirectoryTreeItem extends AzureParentTreeItem<IStorageRoot> impleme
public async copyUrl(): Promise<void> {
let fileService = this.root.createFileService();
let url = fileService.getUrl(this.share.name, this.fullPath);
copypaste.copy(url);
clipboardy.write(url);
ext.outputChannel.show();
ext.outputChannel.appendLine(`Directory URL copied to clipboard: ${url}`);
}
Expand Down
4 changes: 2 additions & 2 deletions src/azureStorageExplorer/fileShares/fileNode.ts
Expand Up @@ -4,7 +4,7 @@
*--------------------------------------------------------------------------------------------*/

import * as azureStorage from "azure-storage";
import * as copypaste from 'copy-paste';
import * as clipboardy from 'clipboardy';
import * as path from 'path';
import { Uri, window } from 'vscode';
import { AzureParentTreeItem, AzureTreeItem, DialogResponses, UserCancelledError } from 'vscode-azureextensionui';
Expand Down Expand Up @@ -35,7 +35,7 @@ export class FileTreeItem extends AzureTreeItem<IStorageRoot> implements ICopyUr
public async copyUrl(): Promise<void> {
let fileService = this.root.createFileService();
let url = fileService.getUrl(this.share.name, this.directoryPath, this.file.name);
copypaste.copy(url);
clipboardy.write(url);
ext.outputChannel.show();
ext.outputChannel.appendLine(`File URL copied to clipboard: ${url}`);
}
Expand Down
4 changes: 2 additions & 2 deletions src/azureStorageExplorer/fileShares/fileShareNode.ts
Expand Up @@ -4,7 +4,7 @@
*--------------------------------------------------------------------------------------------*/

import * as azureStorage from "azure-storage";
import * as copypaste from 'copy-paste';
import * as clipboardy from 'clipboardy';
import * as path from 'path';
import { Uri, window } from 'vscode';
import { AzureParentTreeItem, DialogResponses, UserCancelledError } from 'vscode-azureextensionui';
Expand Down Expand Up @@ -57,7 +57,7 @@ export class FileShareTreeItem extends AzureParentTreeItem<IStorageRoot> impleme
public async copyUrl(): Promise<void> {
let fileService = this.root.createFileService();
let url = fileService.getUrl(this.share.name, "");
copypaste.copy(url);
clipboardy.write(url);
ext.outputChannel.show();
ext.outputChannel.appendLine(`Share URL copied to clipboard: ${url}`);
}
Expand Down
Expand Up @@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/

import * as copypaste from 'copy-paste';
import * as clipboardy from 'clipboardy';
import * as vscode from "vscode";
import { IActionContext, registerCommand, TelemetryProperties } from 'vscode-azureextensionui';
import * as ext from "../../constants";
Expand All @@ -27,12 +27,12 @@ async function openStorageAccountInStorageExplorer(treeItem: StorageAccountTreeI
}

async function copyPrimaryKey(treeItem: StorageAccountTreeItem): Promise<void> {
copypaste.copy(treeItem.key.value);
clipboardy.write(treeItem.key.value);
}

async function copyConnectionString(treeItem: StorageAccountTreeItem): Promise<void> {
let connectionString = await treeItem.getConnectionString();
copypaste.copy(connectionString);
clipboardy.write(connectionString);
}

async function deployStaticWebsite(this: IActionContext, target?: vscode.Uri | StorageAccountTreeItem | BlobContainerTreeItem): Promise<void> {
Expand Down
33 changes: 2 additions & 31 deletions thirdpartynotices.txt
Expand Up @@ -7,9 +7,8 @@ are grateful to these developers for their contribution to open source.

1. node-winreg (https://github.com/fresc81/node-winreg)
2. fs-extra (https://github.com/jprichardson/node-fs-extra)
3. copy-paste (https://github.com/xavi-/node-copy-paste)
4. glob (https://github.com/isaacs/node-glob)
5. opn (https://github.com/sindresorhus/opn)
3. glob (https://github.com/isaacs/node-glob)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need to add clipboardy.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like the opn license was also missing.

Adding that too.

4. opn (https://github.com/sindresorhus/opn)

node-winreg NOTICES BEGIN HERE
=============================
Expand Down Expand Up @@ -46,34 +45,6 @@ OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHE
END OF fs-extra NOTICES AND INFORMATION
==================================

copy-paste NOTICES BEGIN HERE
=============================

The MIT License (MIT)

Copyright (c) 2014

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

END OF copy-paste NOTICES AND INFORMATION
==================================

glob NOTICES BEGIN HERE
=============================

Expand Down