Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add full path to dependencies download #153

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Add full path to dependencies download
PS's DownloadFile cmdlet was downloading to the desktop rather than the script directory, which broke the expand and remove actions when they couldn't find the file. Declared new var that concats script path and dependency name and then uses that for the remainder of actions.
  • Loading branch information
MaleNurse authored Feb 4, 2022
commit 654dfdf8da7792aa04d85d31f258f67dfa07ce0f
7 changes: 4 additions & 3 deletions download_dependencies.ps1
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
function Download($URL, $NAME){

(New-Object System.Net.WebClient).DownloadFile($URL, $NAME+".zip")
Expand-Archive -Path $NAME".zip" -Force
Remove-Item -Path $NAME".zip" -Force
$DEST=$PSScriptRoot+"\"+$NAME+".zip"
(New-Object System.Net.WebClient).DownloadFile($URL, $DEST)
Expand-Archive -Path $DEST -Force
Remove-Item -Path $DEST -Force

}

Expand Down