Skip to content

swolewizard/MinecraftUpdaterForWindows

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 

Repository files navigation

MinecraftUpdater

(Updated by swolewizard for windows from eclair4151)

This is a python package to automate the updating of your server. Its so annoying to try and download the jar, ftp it over, stop the server, back up your world, etc. This automates alll that. just git clone this in the root of your server. Then run python update.py in the server directory. it will check if you have the latest version. If not if will download the latest jar, force close the servers GUI and save the world in the console. it will then backup your world/Previous server.jar into a new folder when it updates incase something goes wrong. then update the server jar and start the server back up in a new console.

With the most recent update.

you can start this script in an empty folder and it'll create/download everything you need and start the server automatically for you

Scheduling Updates, Get your server updated within 1-5mins of an Minecraft update

This script is intended to be run as a cron job/Task.

https://www.windowscentral.com/how-create-automated-task-using-task-scheduler-windows-10

Begin this script/task At startup, repeat task every 5mins, for a duration of Indefinitely.

This will update your server automatically when a new minecraft update is released within 1-5mins.

Capture

Make sure you have a .bat in your server directory where updater.py is located, called 'Manual_run.bat' with

@ECHO OFF

java -Xms4096M -Xmx4096M -jar minecraft_server.jar

pause

If you don't have this .bat, it'll automatically create one for you.

Make sure your server starts with a GUI and console

The way this code works is it force closes java.exe to stop the server enabling the cmd prompt to save the world, so you probably can't host a server and play minecraft at the same time on the same computer. Haven't tested that though

Minecraft-Server-Setup-GUI

Updated java

Make sure your java and java JDK SE is updated, if you're getting server starting errors.

https://www.oracle.com/java/technologies/javase-downloads.html

Requirements

Updated Java

Python

Requests downloaded for python https://pypi.org/project/requests/

Configuration

Latest vs. Snapshot

UPDATE_TO_SNAPSHOT = <True,False>

Backup Directory

BACKUP_DIR =

Backup Previous jars

JARBACKUP_DIR =

Log File

LOG_FILENAME =

About

auto update your minecraft server

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%