Hey everyone,
Today I want to talk about an update to a tool I built a while ago that some of you might remember: mining-arc
. For those who are unfamiliar, it’s a Python script designed to automate the process of distributing dividend tokens to everyone holding a specific "miner" token. It reads its configuration from a .env
file and handles the calculations and transfers for you.
While it has been functional, I decided it was time to give it a much-needed refresh, both under the hood and on the surface.
The Big Overhaul: New Engine, New Look
The biggest changes in this update are:
- Migrated to
hive-nectar
&nectarengine
: The original script was built usingbeem
andhiveengine
. I've now completely migrated it over to use my ownhive-nectar
andnectarengine
libraries. This is part of my ongoing effort to standardize my own tools on a consistent set of libraries that I control and maintain. - Upgraded UI with
rich
: The old version used a combination oftqdm
for progress bars andcolorama
for basic colored text. I've ripped both of those out and replaced them with the excellentrich
library. This provides a much cleaner, more modern, and more readable output in the terminal, complete with nicely formatted tables and progress bars.
Here’s a look at the new summary report the script generates upon completion:
As part of the UI update, I also added a few more useful stats to the final report, like the average number of tokens distributed per holder.
Where to Find It
This tool is designed for anyone who runs a project that pays out dividends to token holders and wants a simple, automated way to handle the distribution. If you want to check it out, use it, or just see how it's built, the full code is available on GitHub. The README
there has instructions on how to set up your .env
file and run it.
- GitHub Repository: https://github.com/TheCrazyGM/mining-arc
It's always satisfying to go back to an older project and give it a fresh coat of paint and a better engine. Let me know what you think!
As always,
Michael Garcia a.k.a. TheCrazyGM