mirror of
https://github.com/ScoopInstaller/Main.git
synced 2025-11-01 14:21:19 +00:00
fix(script): use scoop prefix to correctly find scoop's path (#2878)
* fix(checkver): use scoop prefix to correctly find scoop's path * Update checkver.ps1 * Update auto-pr.ps1 * Update checkurls.ps1 * Update formatjson.ps1 * Update missing-checkver.ps1 * Update test.ps1
This commit is contained in:
parent
30dde179f8
commit
e67399ad69
@ -3,7 +3,7 @@ param(
|
||||
[String]$upstream = "ScoopInstaller/Main:master"
|
||||
)
|
||||
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = resolve-path (split-path (split-path (scoop which scoop))) }
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = Resolve-Path (scoop prefix scoop) }
|
||||
$autopr = "$env:SCOOP_HOME/bin/auto-pr.ps1"
|
||||
$dir = "$psscriptroot/../bucket" # checks the parent dir
|
||||
Invoke-Expression -command "& '$autopr' -dir '$dir' -upstream $upstream $($args | ForEach-Object { "$_ " })"
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = resolve-path (split-path (split-path (scoop which scoop))) }
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = Resolve-Path (scoop prefix scoop) }
|
||||
$checkurls = "$env:SCOOP_HOME/bin/checkurls.ps1"
|
||||
$dir = "$psscriptroot/../bucket" # checks the parent dir
|
||||
Invoke-Expression -command "& '$checkurls' -dir '$dir' $($args | ForEach-Object { "$_ " })"
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = resolve-path (split-path (split-path (scoop which scoop))) }
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = Resolve-Path (scoop prefix scoop) }
|
||||
$checkver = "$env:SCOOP_HOME/bin/checkver.ps1"
|
||||
$dir = "$psscriptroot/../bucket" # checks the parent dir
|
||||
Invoke-Expression -command "& '$checkver' -dir '$dir' $($args | ForEach-Object { "$_ " })"
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = resolve-path (split-path (split-path (scoop which scoop))) }
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = Resolve-Path (scoop prefix scoop) }
|
||||
$formatjson = "$env:SCOOP_HOME/bin/formatjson.ps1"
|
||||
$path = "$psscriptroot/../bucket" # checks the parent dir
|
||||
Invoke-Expression -command "& '$formatjson' -dir '$path' $($args | ForEach-Object { "$_ " })"
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = resolve-path (split-path (split-path (scoop which scoop))) }
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = Resolve-Path (scoop prefix scoop) }
|
||||
$missing_checkver = "$env:SCOOP_HOME/bin/missing-checkver.ps1"
|
||||
$dir = "$psscriptroot/../bucket" # checks the parent dir
|
||||
Invoke-Expression -command "& '$missing_checkver' -dir '$dir' $($args | ForEach-Object { "$_ " })"
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
#requires -Modules @{ ModuleName = 'Pester'; ModuleVersion = '4.4.0' }
|
||||
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = resolve-path (split-path (split-path (scoop which scoop))) }
|
||||
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = Resolve-Path (scoop prefix scoop) }
|
||||
Invoke-Pester "$psscriptroot/.."
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user