My homemade CSV editor

I've tried a few different iterations of expense tracking software through the years (e.g. Mint, YNAB).

Recently there were bugs in the third-party software I was using such that I needed to manually fix the list of transactions in a fairly time-consuming way.

As this wasn't the first time this had happened, and realizing that my actual needs for expense tracking software are very low, I decided to quit paying for a third-party service and just build exactly what I needed with some simple python scripts.

The end result is a small amount of python code that takes files exported from my bank/credit card, and dumps the transactions into a CSV file, automatically categorizing some transactions (Fun/Giving/Transportation etc.). From there, I edit the CSV and finish categorizing the remaining transactions.

Building a CSV Editor

There's lots of programs for editing CSVs, but one feature I really miss when editing CSVs in something like Excel is the ability to have multiple cursors at once.

So, I decided to build myself a CSV editor! I was inspired by Nikita's use of Skia to make a quick-and-dirty UI for a programming contest here.

Since I'm just building this for myself, I can make a lot of tradeoffs that I wouldn't make in production code:

Results

The finished program is <1000 lines of python code. It relies on skia-python and GLFW, and it took me a couple of days to get working how I want.

Skia is a graphics library, not a UI library, which means it knows how to draw shapes, not higher levels of abstractions like buttons or tables. Fortunately, my layout is very simple: a row of absolutely positioned buttons across the top, and a table.

Here's the multiple cursors feature in action on some dummy data:

My gif

I didn't know how easy it was to write a native application with a high-level language like python!

This seems like an ideal stack for quick projects/games like this that don't need in-depth layout systems.

Recap

It was really enjoyable to write software for myself.

Part of my brain kept saying I should open-source the project, or write the code to be more robust, but in the end this was a simple side project that accomplished all its goals without a lot of fuss.