aboutsummaryrefslogtreecommitdiff
path: root/docs/finbudg.5.scd
blob: ae485c1faa3009310610262738dcbc62a33aac77 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
finbudg(5)

# NAME

finbudg - Quick cli tool to calculate your expenses and balance for a set period
of time.

# DESCRIPTION

This manual page documents the syntax of the expenses files used by the
*finbudg* program.

# SYNTAX

Expenses files used by *finbudg* use the toml file format as their base for the
syntax.

## PREAMBLE

The expenses file should contain at the start the following keys:

*start_date*=YYYY-MM-DD
	This is the date when the period for this budget starts, e.g. your payday.

*end_date*=YYYY-MM-DD
	This is the date when the period for this budget ends, e.g. the day before
	your next payday.

*budget*=float64
	A floating point number that represents your budget for the specified period
	of time.

*essential_categories*=String[]
	An array of strings representing the categories that you want to take into
	account as "essential". _Optional_.

*[[days]]*
	An entry of this type is an entry for the array of tables *days* and
	contains the following keys:

		*date*=YYYY-MM-DD
			The date for this day when the following expenses were made.

		*[[days.expenses]]*
			An entry of this type is an entry for the nested array of tables
			*expenses* inside of an entry of type *days*. It may contain the
			following keys:

				*name*=String
					The name of the product/service/etc. that money was spent
					on.

				*price*=float64
					How much money was spent on said product/service/etc.

				*category*=String
					The category to which this expense belongs. _Optional_.

				*shared*=array<String>
					An list of names of the people that this expense is shared
					with proportionally. If owed equals true, then you are not
					part of this expense, and the people listed here owe you all
					of this expense. _Optional_.

				*owed*=boolean
					A boolean value that indicates whether you paid for this for
					another person or persons. If set to true, then shared
					should contain at least one name. _Optional_.


# NOTES

The dates should be in ISO 8601 format with *NO* time in them, e.g.
*2020-04-20*.

You don't have to include every day in the period in your expenses file if you
didn't spend any money that day. The program will take into account the last
date in the file to count the number of days. Also, the *[[days.expenses]]* key
is optional, you can also include a day and omit the expenses.

If you're not very familiar with the TOML format, you should take a look at
*https://toml.io/en/v1.0.0-rc.2*. Especially the part about arrays of tables.

If you're still not sure how the input file should look like, or if you prefer
to learn by example, take a look at *https://github.com/Yaroslav-95/finbudg*.
The README.md includes an example of an expense file.

# SEE ALSO

*finbudg*(1)

# AUTHORS

Yaroslav de la Peña Smirnov <yps@yaroslavps.com>.