Created
December 15, 2022 09:18
-
-
Save jpluimers/866c1402e92f41dd8da8cfd45763b785 to your computer and use it in GitHub Desktop.
Quick batch file hack to download a file calling PowerShell to do the heavy lifting
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
if "%1"=="" goto :help | |
@echo on | |
powershell.exe -Command (New-Object System.Net.WebClient).DownloadFile('%1','%2') | |
@echo off | |
goto :eof | |
:help | |
echo Syntax: %0 URL local-filename |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment