Skip to content

Commit ce1ef8b

Browse files
committed
feat: check if file already exists in Windows install script (#48)
1 parent 93cb418 commit ce1ef8b

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

install.ps1

+3
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@ Push-Location $envfetchPath
77

88
try {
99
$outFile = "envfetch.exe"
10+
if ([System.IO.File]::Exists($outFile)) {
11+
Write-Host "envfetch already exists. Updating..."
12+
}
1013
Invoke-WebRequest -Uri "https://github.com/ankddev/envfetch/releases/latest/download/envfetch-windows-amd64.exe" -OutFile $outFile
1114

1215
# Check integrity

0 commit comments

Comments
 (0)