Skip to content

Scripting

Automating Mod Downloads from Curseforge for Servers

I like modded Mincraft. I was trying to setup a modded server from Curseforge and found out that there are a number of mods that are flagged to not auto download with the rest of the pack. During the server pack install a file called "MODS_NEED_DOWNLOAD.txt" will be created containing various mods that meed this criteria. The expectation being you need to download each one and copy it to the server pack mods directory.

Poor Mans Connection Monitoring

This morning I had need to be alerted if I ping starts failing in an ad-hoc situation. The below script does a test ping and then beeps if the ping fails. It'll loop endlessly.

while ($true) {
    $ping = Test-Connection -ComputerName 10.120.10.100 -Count 1
    $ping
    Start-Sleep -Seconds 1
    If (($ping -eq "") -or ($ping -eq $null)) {
        [console]::beep(500,1000)
    }
}