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

🤖 Add vscode.vm #888

Merged
merged 1 commit into from
Feb 18, 2024
Merged
Show file tree
Hide file tree
Changes from all 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
15 changes: 15 additions & 0 deletions packages/vscode.vm/tools/chocolateyinstall.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
$ErrorActionPreference = 'Stop'
Import-Module vm.common -Force -DisableNameChecking

try {
$toolName = 'VSCode'
$category = 'Text Editors'
emtuls marked this conversation as resolved.
Show resolved Hide resolved

$shortcutDir = Join-Path ${Env:TOOL_LIST_DIR} $category
$shortcut = Join-Path $shortcutDir "$toolName.lnk"
$executablePath = Join-Path ${Env:ProgramFiles} "\Microsoft VS Code\Code.exe" -Resolve
VM-Install-Shortcut -toolName $toolName -category $category -executablePath $executablePath -runAsAdmin
VM-Assert-Path $shortcut
} catch {
VM-Write-Log-Exception $_
}
7 changes: 7 additions & 0 deletions packages/vscode.vm/tools/chocolateyuninstall.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
$ErrorActionPreference = 'Continue'
Import-Module vm.common -Force -DisableNameChecking

$toolName = 'VSCode'
$category = 'Text Editors'

VM-Remove-Tool-Shortcut $toolName $category
13 changes: 13 additions & 0 deletions packages/vscode.vm/vscode.vm.nuspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2015/06/nuspec.xsd">
<metadata>
<id>vscode.vm</id>
<version>1.85.2</version>
<authors>Microsoft</authors>
<description>VSCode is a modern, open-source code editor.</description>
<dependencies>
<dependency id="common.vm" />
<dependency id="vscode.install" version="[1.85.2]" />
</dependencies>
</metadata>
</package>
Loading