Hacker News new | ask | show | jobs
Show HN: Using mkdir to track financial transactions (github.com)
8 points by elpachongco 975 days ago
I've been exploring uses of file metadata. Here's an interesting one with a legitimate (and potentially unreliable) use case. Focuses on ease of use.

Would love to hear feedback.

4 comments

"My goal is to create the easiest way to enter transactions for those who live in the terminal."

Are you TRYING to make your life difficult? :)

How about a 'simple' spreadsheet, with Date, Amount, Currency, Shop/Vendor, and then 2-3 columns with "Necessary/Unnecessary/Junk", "BAU/Vacations/Work", and/or Town (to be able to calculate that your trip to Paris actually cost a total of X (tickets, hotel, drinks, etc).

I spent a lot of time trying to solve this for myself, and trust me when I tell you.. mkdir for transactions did not cross my mind at all :)

EDIT: with an excel spreadsheet you can then use Pivot tables to get meaningful data per-category-per-month so you can see side-by-side that groceries in June-at-home cost less than groceries in-September-at-home (and so on).

Yes it's not for everyone. But in my defense, difficult is subjective. I built this for me because this is easier to me. It's a single line I have to keep in mind. The goal here is to remove the friction on entering the data. It means that it has to be highly available, fast, and easy. Though, I admit even I'm not sure if this project can actually achieve those things (even for me)[1].

This is just a personal experiment that I wanted to share.

I've actually tried the spreadsheet approach for 6 months. I tried to record all transactions I made in those 6 months. What I've observed is that it becomes too slow. Maybe there are clever workarounds but the spreadsheet just feels unfriendly to me. Also, I usually have slow 4g connection (Philippines) and I'm using a phone from 2016[2]. These variables are guranteed to NOT make a frictionless experience.

> I spent a lot of time trying to solve this for myself, and trust me when I tell you.. mkdir for transactions did not cross my mind at all :)

Haha. I've been working on exiftool and was looking for methods to track every transaction I have. I'm not sure what happened.

I don't know how useful this will become but learning awk is a nice side effect.

> How about a 'simple' spreadsheet, with Date, Amount, Currency, Shop/Vendor, and then 2-3 columns with "Necessary/Unnecessary/Junk", "BAU/Vacations/Work", and/or Town (to be able to calculate that your trip to Paris actually cost a total of X (tickets, hotel, drinks, etc).

This approach doesn't scale for me. Sure, tools can handle the data but can you? I sure can't. When a busy month comes, that's going to be a messy spreadsheet with gaps. Which makes the month-per-month comparisons almost impossible.

Also, do you need that much data? I'm only concerned about where things go so I think this is enough.

[1] as stated in the README: https://github.com/elpachongco/finance-tracker#state-of-this...

[2] I've written a bit about the phone: https://elpachongco.github.io/uses/#the-phone---lg-v20

Two advantages to this:

- muscle memory is easy to change

- format is easy to migrate

One migration would be sqlite, which has advantages:

- found everywhere with Python

- A custom command to slot in for mkdir would be maybe 10 lines

- sharing is straightforward

- if kept simple-enough, two unrelated databases can be manually merged offline with two `sqlite dump` text files. I do the manual merge all the time within vim:

    autocmd FileType sql let &makeprg='sqlite3 %:r:s/-[0-9]*//:S.db ".read %:S"'
This will feed your vim buffer into a probably-new database
If this works for you, great, but seems overly complicated.

Possibly you could support double entry accounting with diff? :)

You might enjoy ledger (cli tool)!