Skip to content

Commit 2db94cf

Browse files
committed
Changed double quotes to single quotes when suitable
Bumped version to 1.4.1
1 parent 96addda commit 2db94cf

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

scripts/Install-VSCode.ps1

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<#PSScriptInfo
22
3-
.VERSION 1.4.0
3+
.VERSION 1.4.1
44
55
.GUID 539e5585-7a02-4dd6-b9a6-5dd288d0a5d0
66
@@ -130,11 +130,11 @@
130130
[CmdletBinding(SupportsShouldProcess=$true)]
131131
param(
132132
[parameter()]
133-
[ValidateSet(, "64-bit", "32-bit")]
134-
[string]$Architecture = "64-bit",
133+
[ValidateSet('64-bit', '32-bit')]
134+
[string]$Architecture = '64-bit',
135135

136136
[parameter()]
137-
[ValidateSet("Stable-System","Stable-User", "Insider-System", "Insider-User")]
137+
[ValidateSet('Stable-System', 'Stable-User', 'Insider-System', 'Insider-User')]
138138
[string]$BuildEdition = "Stable-System",
139139

140140
[Parameter()]
@@ -168,7 +168,7 @@ gpgkey=https://packages.microsoft.com/keys/microsoft.asc
168168

169169
function Test-IsOsArchX64 {
170170
if ($PSVersionTable.PSVersion.Major -lt 6) {
171-
return (Get-CimInstance -ClassName Win32_OperatingSystem).OSArchitecture -eq "64-bit"
171+
return (Get-CimInstance -ClassName Win32_OperatingSystem).OSArchitecture -eq '64-bit'
172172
}
173173

174174
return [System.Runtime.InteropServices.RuntimeInformation]::OSArchitecture -eq [System.Runtime.InteropServices.Architecture]::X64
@@ -404,19 +404,19 @@ function Save-WithBitsTransfer {
404404

405405
$bitsDl = Start-BitsTransfer $FileUri -Destination $Destination -Asynchronous
406406

407-
while (($bitsDL.JobState -eq "Transferring") -or ($bitsDL.JobState -eq "Connecting")) {
407+
while (($bitsDL.JobState -eq 'Transferring') -or ($bitsDL.JobState -eq 'Connecting')) {
408408
Write-Progress -Activity "Downloading: $AppName" -Status "$([math]::round($bitsDl.BytesTransferred / 1mb))mb / $([math]::round($bitsDl.BytesTotal / 1mb))mb" -PercentComplete ($($bitsDl.BytesTransferred) / $($bitsDl.BytesTotal) * 100 )
409409
}
410410

411411
switch ($bitsDl.JobState) {
412412

413-
"Transferred" {
413+
'Transferred' {
414414
Complete-BitsTransfer -BitsJob $bitsDl
415415
break
416416
}
417417

418-
"Error" {
419-
throw "Error downloading installation media."
418+
'Error' {
419+
throw 'Error downloading installation media.'
420420
}
421421
}
422422
}
@@ -433,7 +433,7 @@ function Install-VSCodeFromTar {
433433
)
434434

435435
$tarDir = Join-Path ([System.IO.Path]::GetTempPath()) 'VSCodeTar'
436-
$destDir = "/opt/VSCode-linux-x64"
436+
$destDir = '/opt/VSCode-linux-x64'
437437

438438
New-Item -ItemType Directory -Force -Path $tarDir
439439
try {

0 commit comments

Comments
 (0)