Simple Bash script to check for NostalgiaForInfinity newly added tags or commits and update it for usage with Freqtrade bot.
- Both
freqtrade
andNostalgiaForInfinity
folders are in the same path level (e.g. /home/ubuntu)
Clone the repo:
git clone https://github.com/krsh-off/nfi-tags-auto-update.git
Open update.sh
file and tweak some variables:
ROOT_PATH
- path to the directory whereNostalgiaForInfinityNext
andfreqtrade
directories are placesTG_TOKEN
- Telegram token you've got for the botTG_CHAT_ID
- Telegram chat ID with your botTG_FT_BOT_ID
- Telegram ID of your Freqtrade bot, the one that ends inbot
MODE
- check out tags (default) or latest commit in the repoAUTO_RELOAD
- keep ittrue
if you want to fully automate the process
Make the file executable:
chmod +x update.sh
Setup a Cron job to execute the script periodically.
Log into your server and type crontab -e
. Next you should be editing the cron file, add in the following line at the bottom of the file.
*/30 * * * * /bin/bash -c "nfi-tags-auto-update/update.sh"
Once that is saved, the updater will check for new git updates every 30 mins and notify you via Telegram if there was anything new so you can restart it.