Skip to content

Instantly share code, notes, and snippets.

@mihionmc
Created February 15, 2020 22:03
Show Gist options
  • Save mihionmc/a60196cb1af36a776ceb6dfd0c19bc66 to your computer and use it in GitHub Desktop.
Save mihionmc/a60196cb1af36a776ceb6dfd0c19bc66 to your computer and use it in GitHub Desktop.
#!/bin/sh
# mihion.dk
# a shell script used to download a specific url.
# this is executed from a crontab entry every day.
DIR=/home/zen/srv/vanillamc
cd $DIR
rm -r vmc.jar
# wget output file
#FILE=dailyinfo.`date +"%Y%m%d"`
# wget log file
LOGFILE=get.log
# wget download url
URL1=https://papermc.io/api/v1/paper/1.15.2/latest/download
cd $DIR
wget --content-disposition -O vmc.jar $URL1 -o $LOGFILE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment