Selected work
Automation Tool · Node.jsNode.js · JavaScript

Minecraft Screenshots Uploader

Watches your Minecraft screenshots folder and automatically posts new images to Discord via webhook.

A lightweight file watcher that monitors the Minecraft screenshots directory and queues new PNG files for automatic upload to Discord. Built for capturing gameplay moments hands-free with a simple webhook integration.

Role — Solo developer
  • Node.js
  • JavaScript
  • fs (file system)
  • axios
  • dotenv
  • Discord Webhooks

This tool solves a specific friction point: I take a lot of Minecraft screenshots but manually copying them to Discord is tedious. The uploader runs in the background, detecting new PNGs as they're written to disk and posting them to a Discord channel in real-time.

The architecture is straightforward: fs.watch monitors the screenshots directory, new files trigger a 2-second settle timer (to wait for disk writes to complete), then the file gets queued and uploaded sequentially via axios and Discord webhooks. The queue ensures uploads don't pile up or race; graceful shutdown waits for in-flight uploads to finish before exiting.

It handles real-world gotchas like incomplete file writes, deleted files between detection and upload, and missing CurseForge instances. Environment-based configuration keeps the Discord webhook URL out of source control, and the settle-time approach avoids the common race condition of trying to read files still being written by Minecraft.

What's notable
  • File watching with 2-second settle time prevents attempts to upload incomplete writes
  • Sequential queue-based uploads via axios with configurable concurrency limits
  • Graceful shutdown that waits for pending uploads to complete before exiting
  • CurseForge instance discovery across multiple common installation paths
  • Automatic retry logic and file existence checks during queue processing