-
Notifications
You must be signed in to change notification settings - Fork 7
feat: package manager permissions when using API #218
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
Draft
karthiknadig
wants to merge
10
commits into
microsoft:main
Choose a base branch
from
karthiknadig:permissions-flow1
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
3ac27f3
feat: package manager permissions when using API
karthiknadig 1a2a6dd
fix: address comments
karthiknadig f24dead
chore: some refactoring
karthiknadig 42122c9
fix: reduce extension list for permissions check to installed extensions
karthiknadig e9f5f9a
fix: use vsceTarget to rustTarget conversion when pulling `pet` (#225)
karthiknadig 1fcb7b9
fix: UX when installing packages (#222)
karthiknadig 8f4cd45
fix: package refresh issue when installed externally (#253)
karthiknadig d65b796
Bump tar-fs from 2.1.1 to 2.1.2 (#255)
dependabot[bot] 62a894e
feat: package manager permissions when using API
karthiknadig e79795f
fix to remove application from paths list
eleanorjboyd File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,11 @@ | ||
/* eslint-disable @typescript-eslint/no-explicit-any */ | ||
import { commands } from 'vscode'; | ||
import { Disposable } from 'vscode-jsonrpc'; | ||
|
||
export function executeCommand<T = unknown>(command: string, ...rest: any[]): Thenable<T> { | ||
return commands.executeCommand(command, ...rest); | ||
} | ||
|
||
export function registerCommand(command: string, callback: (...args: any[]) => any, thisArg?: any): Disposable { | ||
return commands.registerCommand(command, callback, thisArg); | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -144,3 +144,10 @@ export namespace EnvViewStrings { | |||||
export const selectedGlobalTooltip = l10n.t('This environment is selected for non-workspace files'); | ||||||
export const selectedWorkspaceTooltip = l10n.t('This environment is selected for workspace files'); | ||||||
} | ||||||
|
||||||
export namespace PermissionsCommon { | ||||||
export const allow = l10n.t('Allow'); | ||||||
export const deny = l10n.t('Deny'); | ||||||
export const ask = l10n.t('Ask'); | ||||||
export const setPermissions = l10n.t('Set Permissions'); | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,9 @@ | ||
import * as path from 'path'; | ||
import { isWindows } from '../../managers/common/utils'; | ||
|
||
export function areSamePaths(a: string, b: string): boolean { | ||
return path.resolve(a) === path.resolve(b); | ||
} | ||
|
||
export function isParentPath(parent: string, child: string): boolean { | ||
const relative = path.relative(path.resolve(parent), path.resolve(child)); | ||
return !!relative && !relative.startsWith('..') && !path.isAbsolute(relative); | ||
export function normalizePath(path: string): string { | ||
const path1 = path.replace(/\\/g, '/'); | ||
if (isWindows()) { | ||
return path1.toLowerCase(); | ||
} | ||
return path1; | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure "Ask" is easily understandable in this context. I wonder if we should do something like "Always Ask" or "Confirm each time" at the tradeoff of having a slightly longer button title
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
agreed- I also wanted this button to be explicit it was a long-term choice