Skip to content

Commit

Permalink
refactor(COMSPEC): Deprecate use of subshell cmd.exe (ScoopInstaller#…
Browse files Browse the repository at this point in the history
  • Loading branch information
rashil2000 authored and se35710 committed Mar 8, 2022
1 parent 28ca55c commit c4a83e8
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 12 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
- **depends:** Keep bucket in 'Get-Dependency()' ([#4673](https://github.com/ScoopInstaller/Scoop/issues/4673))
- **mklink:** Use 'New-Item' instead of 'mklink' ([#4690](https://github.com/ScoopInstaller/Scoop/issues/4690))
- **rmdir:** Use 'Remove-Item' instead of 'rmdir' ([#4691](https://github.com/ScoopInstaller/Scoop/issues/4691))
- **COMSPEC:** Deprecate use of subshell cmd.exe ([#4692](https://github.com/ScoopInstaller/Scoop/pull/4692))

### Builds

Expand Down
10 changes: 0 additions & 10 deletions lib/diagnostic.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,3 @@ function check_long_paths {
return $true
}

function check_envs_requirements {
if ($null -eq $env:COMSPEC) {
warn '$env:COMSPEC environment variable is missing.'
Write-Host " By default the variable should point to the cmd.exe in Windows: '%SystemRoot%\system32\cmd.exe'."

return $false
}

return $true
}
2 changes: 1 addition & 1 deletion lib/git.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ function git_proxy_cmd {
if($proxy -and $proxy -ne 'none') {
$cmd = "SET HTTPS_PROXY=$proxy&&SET HTTP_PROXY=$proxy&&$cmd"
}
& "$env:COMSPEC" /d /c $cmd
cmd.exe /d /c $cmd
}

function git_clone {
Expand Down
1 change: 0 additions & 1 deletion libexec/scoop-checkup.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ $issues += !(check_windows_defender $false)
$issues += !(check_windows_defender $true)
$issues += !(check_main_bucket)
$issues += !(check_long_paths)
$issues += !(check_envs_requirements)

if (!(Test-HelperInstalled -Helper 7zip)) {
error "'7-Zip' is not installed! It's required for unpacking most programs. Please Run 'scoop install 7zip' or 'scoop install 7zip-zstd'."
Expand Down

0 comments on commit c4a83e8

Please sign in to comment.