The repository includes two shell scripts to help you operate the bot:Documentation Index
Fetch the complete documentation index at: https://mintlify.com/joshuaKnauber/serpens_addon_market/llms.txt
Use this file to discover all available pages before exploring further.
run.sh starts the bot as a background process and routes all output to a log file, while gitpush.sh lets you manually sync any direct changes to the JSON data files back to the remote repository. Together they provide a lightweight operational workflow for keeping the marketplace running and its data versioned.
Starting the Bot
Update the working directory path in run.sh
The The script creates
run.sh script contains a hardcoded absolute path that must match your system. Open the file and replace /home/finn/serpens_addon_market/ with the actual path to your cloned repository:run.sh
output.log if it does not exist, then launches serpens_bot.py with nohup so the process continues running after your shell session ends. Both stdout and stderr are appended to output.log.Make the script executable and run it
Stopping the Bot
The bot runs as a background process undernohup. To stop it, find its process ID and send a termination signal:
Automatic Git Sync
Every time the bot finishes processing a Discord message — whether it was an upload, update, removal, or just an unrecognized command — it runs the following four commands viaos.system:
serpens_bot.py
Serverlog, pulled from remote to incorporate any concurrent changes, and then pushed back to GitHub. The git pull before git push is intentional — it reduces the chance of a rejected push when the remote has diverged. The working directory must have git configured with push access at all times, and the bot must be run from inside the repository directory (which run.sh ensures via cd).
All four git commands are called with
os.system, which does not raise a Python exception if a command fails. If your SSH keys or credential cache are not configured, the push will silently fail on every message — no error will appear in output.log unless git itself writes to stderr. Verify the sync is working by checking your remote repository’s commit history for Serverlog commits.Manual Push with gitpush.sh
If you editaddons.json, snippets.json, or packages.json directly — for example to fix a broken entry or remove stale data — those changes will not be auto-pushed because the bot only triggers the sync on Discord message events. Use gitpush.sh to manually sync them:
gitpush.sh
Monitoring
All bot output — including the startup message, Discord events, and any Python errors — is captured inoutput.log by run.sh.
- Watch live output:
- View the last 50 lines:
- Truncate the log when it grows too large (the log is never rotated automatically):
