'switch wget from macOS to windows
I'm using the following script to check if a new file was uploaded to a specific adress on my Mac. gotta switch to a windows PC
Any idea how to have the same function or similar on windows?
while ! wget https://xxxxxxxxxxxx/xxxxxx/xx-$ sleep 10 done afplay /System/Library/Sounds/Funk.aiff say file found osascript -e 'tell app "System Events" to display dialog "Wow.. exciting file downloaded!"'
Solution 1:[1]
this is an example in powershell:
$var = $true
while($var){
try
{
$request = Invoke-WebRequest -Uri "https://de.wikipedia.org/favicon.ico" -OutFile "C:\fav.ico"
[System.Media.SystemSounds]::Asterisk.Play()
[System.Reflection.Assembly]::LoadWithPartialName("System.Windows.Forms")
[System.Windows.Forms.MessageBox]::Show("Wow.. exciting file downloaded!","Msg",0)
$var = $false
}
catch{
Start-Sleep -s 10
}
}
How do you get Windows PowerShell to play a sound after .bat job has finished running?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | FloriEnder |
