Corrections and Dir already present
parent
e2c8e3cf21
commit
dabc0d165f
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
function Test-Mods ($app){
|
function Test-Mods ($app){
|
||||||
|
|
||||||
|
if (Test-Path "$WorkingDir\mods\$app-*"){
|
||||||
if (Test-Path "$WorkingDir\mods\$app-install.ps1"){
|
if (Test-Path "$WorkingDir\mods\$app-install.ps1"){
|
||||||
$ModsInstall = "$WorkingDir\mods\$app-install.ps1"
|
$ModsInstall = "$WorkingDir\mods\$app-install.ps1"
|
||||||
$ModsUpgrade = "$WorkingDir\mods\$app-install.ps1"
|
$ModsUpgrade = "$WorkingDir\mods\$app-install.ps1"
|
||||||
|
@ -9,10 +10,10 @@ function Test-Mods ($app){
|
||||||
if (Test-Path "$WorkingDir\mods\$app-upgrade.ps1"){
|
if (Test-Path "$WorkingDir\mods\$app-upgrade.ps1"){
|
||||||
$ModsUpgrade = "$WorkingDir\mods\$app-upgrade.ps1"
|
$ModsUpgrade = "$WorkingDir\mods\$app-upgrade.ps1"
|
||||||
}
|
}
|
||||||
|
return $ModsInstall,$ModsUpgrade
|
||||||
|
}
|
||||||
else {
|
else {
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
return $ModsInstall,$ModsUpgrade
|
|
||||||
|
|
||||||
}
|
}
|
|
@ -31,10 +31,6 @@ function Update-WAU {
|
||||||
$TempPath = (Resolve-Path "$location\*\Winget-AutoUpdate\")[0].Path
|
$TempPath = (Resolve-Path "$location\*\Winget-AutoUpdate\")[0].Path
|
||||||
if ($TempPath){
|
if ($TempPath){
|
||||||
Copy-Item -Path "$TempPath\*" -Destination "$WorkingDir\" -Exclude "icons" -Recurse -Force
|
Copy-Item -Path "$TempPath\*" -Destination "$WorkingDir\" -Exclude "icons" -Recurse -Force
|
||||||
#Add 'mods' directory
|
|
||||||
if (!(Test-Path "$WorkingDir\mods")){
|
|
||||||
New-Item -ItemType Directory -Force -Path "$WingetUpdatePath\mods"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#Remove update zip file and update temp folder
|
#Remove update zip file and update temp folder
|
||||||
|
|
Loading…
Reference in New Issue