{"id":20509671,"url":"https://github.com/elpachongco/finance-tracker","last_synced_at":"2026-03-08T19:35:11.669Z","repository":{"id":200325137,"uuid":"705273028","full_name":"elpachongco/finance-tracker","owner":"elpachongco","description":"Use mkdir to track financial transactions ","archived":false,"fork":false,"pushed_at":"2023-10-16T10:15:03.000Z","size":52,"stargazers_count":12,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-16T08:36:43.123Z","etag":null,"topics":["plaintext-accounting"],"latest_commit_sha":null,"homepage":"","language":"Awk","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/elpachongco.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-10-15T14:56:44.000Z","updated_at":"2023-10-18T18:06:35.000Z","dependencies_parsed_at":null,"dependency_job_id":"afca8a62-653c-4e0c-93d7-fcec71b697a5","html_url":"https://github.com/elpachongco/finance-tracker","commit_stats":null,"previous_names":["elpachongco/finance-tracker"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elpachongco%2Ffinance-tracker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elpachongco%2Ffinance-tracker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elpachongco%2Ffinance-tracker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elpachongco%2Ffinance-tracker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elpachongco","download_url":"https://codeload.github.com/elpachongco/finance-tracker/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242112301,"owners_count":20073566,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["plaintext-accounting"],"created_at":"2024-11-15T20:25:57.409Z","updated_at":"2026-03-08T19:35:11.629Z","avatar_url":"https://github.com/elpachongco.png","language":"Awk","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Personal Finance Tracker\n\nA framework for tracking transactions\n\n![](demo.png)\n\n## Usage\n\n```sh\n# Save a transaction\nmkdir -p tx/25XMR/nft/\"sold pixelart\"\n\n# Paid public transport?\nmkdir -p tx/-25PHP/fare/\"from town to home\"\n\n# Received a gift?\nmkdir -p tx/+25,000PHP/gift/\"Mrs. Robinson's gift\"\n```\n\nExample: `mkdir -p tx/25XMR/nft/\"sold pixel art\"` wherein\n\n- `25` is the amount. It can be negative for expenses or positive for inflow.\n- `XMR` is the currency\n- `nft` is the transaction category \n- `sold pixelart` is the description of the transaction. \n    If this is a recurring transaction, $RANDOM can be used for each instance of transaction .e.g. \n    ```sh\n    mkdir -p tx/12PHP/fare/\"House to town $RANDOM\"\n    ```\n\n    Note: It's okay to use `$RANDOM` because this framework depends on the datetime metadata of the directory.\n    \n    Metadata is key for this project to work[^1]. Therefore, moving the files to a file system that doesn't support or modifies the datetime metadata is dangerous.\n\n[^1]: Because dates are not easy to enter manually, we let the file system handle it.\n\nTo view all transactions:\n\n```sh\n# Simplest way to do see transactions is to use tree\n$ tree -tr tx\ntx\n├── 13PHP\n│   └── fare\n│       └── 6839\n├── +13,000.05PHP\n│   └── salary\n│       └── 24938\n├── -13PHP\n│   └── fare\n│       ├── from town to home 27170\n│       ├── 2023-10-15\n│       └── 14:56:14\n├── -18PHP\n│   └── fare\n│       ├── 24007 town to home\n│       ├── 29131 home to town\n│       ├── 13766 home to town\n│       ├── 26765\n│       └── 26522\n└── 25PHP\n    └── payment16139\n```\n\n```sh\n# This lists all the transactions (leafs of the directory tree)\n$ find tx -type d -empty -exec stat --format=\"%y %n\" {} \\;\n2023-10-15 16:39:50.822795281 +0800 tx/+13,000.05PHP/salary/24938\n2023-10-15 14:43:37.997293092 +0800 tx/-18PHP/fare/29131 home to town\n2023-10-15 14:43:22.853190549 +0800 tx/-18PHP/fare/13766 home to town\n2023-10-15 14:43:04.981069469 +0800 tx/-18PHP/fare/26765\n2023-10-15 14:59:29.059628490 +0800 tx/-18PHP/fare/24007 town to home\n2023-10-15 14:38:44.579320316 +0800 tx/-18PHP/fare/26522\n2023-10-15 14:56:14.646349096 +0800 tx/-13PHP/fare/14:56:14\n2023-10-15 14:56:42.582533401 +0800 tx/-13PHP/fare/2023-10-15\n2023-10-15 16:44:14.909531796 +0800 tx/-13PHP/fare/from town to home 27170\n2023-10-15 13:42:23.272353225 +0800 tx/25PHP/payment16139\n2023-10-15 22:47:43.678019774 +0800 tx/13PHP/fare/6839\n```\n\n```sh\n# Get the total of the transactions:\n$ find tx -type d -empty -exec stat --format=\"%y %n\" {} \\; | awk '{print $4}' | awk -F '/' '{ print $2}' | awk '{ gsub(/[^0-9.-]/, \"\"); sum += $1 } END { print sum }'\n12909\n```\n\nScripts are also available:\n```\n# pretty printed transactions:\n$ show/tx.sh\n0   date        time   currency  type  amount    category\n1   2023-10-15  22:47  PHP       +     13        fare\n2   2023-10-15  16:44  PHP       -     13        fare\n3   2023-10-15  16:39  PHP       +     13000.05  salary\n4   2023-10-15  14:59  PHP       -     18        fare\n5   2023-10-15  14:56  PHP       -     13        fare\n6   2023-10-15  14:56  PHP       -     13        fare\n7   2023-10-15  14:43  PHP       -     18        fare\n8   2023-10-15  14:43  PHP       -     18        fare\n9   2023-10-15  14:43  PHP       -     18        fare\n10  2023-10-15  14:38  PHP       -     18        fare\n11  2023-10-15  13:42  PHP       +     25        payment16139\n```\n\n## Why? \n\nI tried different ways of tracking expenses but it always fails because \nentering every transaction is a hassle. \n\nMy goal is to create the easiest way to enter transactions for those\nwho live in the terminal.\n\nI definitely did not make this to try out awk.\n\n## State of this project\n\nI don't consider this usable yet. It's still in the exploration state.\n\nSome problems:\n- How do you do this on mobile (syncthing?)\n- What if I have multiple stores of wealth?\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felpachongco%2Ffinance-tracker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felpachongco%2Ffinance-tracker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felpachongco%2Ffinance-tracker/lists"}