hledger

package module
v0.9.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 30, 2024 License: MIT Imports: 8 Imported by: 3

Documentation

Index

Constants

View Source
const (
	LayoutBare      LayoutType = "bare"
	PeriodDaily     PeriodType = "--daily"
	PeriodWeekly    PeriodType = "--weekly"
	PeriodMonthly   PeriodType = "--monthly"
	PeriodQuarterly PeriodType = "--quarterly"
	PeriodYearly    PeriodType = "--yearly"
)

Variables

This section is empty.

Functions

func ParseCSV

func ParseCSV(r io.Reader) ([][]string, error)

Types

type Error

type Error struct {
	// contains filtered or unexported fields
}

func (*Error) Args

func (e *Error) Args() []string

func (*Error) Error

func (e *Error) Error() string

func (*Error) Msg

func (e *Error) Msg() string

type Hledger

type Hledger struct {
	// contains filtered or unexported fields
}

func New

func New(hledgerBinary, journalFile string) Hledger

func NewDebug

func NewDebug(hledgerBinary, journalFile string, logWriter io.Writer) Hledger

func (Hledger) Accounts added in v0.9.0

func (h Hledger) Accounts(options Options) (io.Reader, error)

func (Hledger) Assets

func (h Hledger) Assets(options Options) (io.Reader, error)

func (Hledger) Balance

func (h Hledger) Balance(options Options) (io.Reader, error)

func (Hledger) BalanceSheet

func (h Hledger) BalanceSheet(options Options) (io.Reader, error)

func (Hledger) Expenses

func (h Hledger) Expenses(options Options) (io.Reader, error)

func (Hledger) IncomeStatement

func (h Hledger) IncomeStatement(options Options) (io.Reader, error)

func (Hledger) Liabilities

func (h Hledger) Liabilities(options Options) (io.Reader, error)

func (Hledger) Register

func (h Hledger) Register(options Options) (io.Reader, error)

func (Hledger) Revenue

func (h Hledger) Revenue(options Options) (io.Reader, error)

type LayoutType

type LayoutType string

type Options

type Options struct {
	// contains filtered or unexported fields
}

func NewOptions

func NewOptions() Options

func (Options) Build

func (o Options) Build() []string

func (Options) WithAccount

func (o Options) WithAccount(account string) Options

func (Options) WithAccountDepth

func (o Options) WithAccountDepth(depth int) Options

func (Options) WithAccountDrop

func (o Options) WithAccountDrop(drop int) Options

func (Options) WithAccountType

func (o Options) WithAccountType(accountType string) Options

func (Options) WithAverage

func (o Options) WithAverage() Options

func (Options) WithDescription

func (o Options) WithDescription(description string) Options

func (Options) WithEndDate

func (o Options) WithEndDate(endDate string) Options

func (Options) WithInvertAmount

func (o Options) WithInvertAmount() Options

func (Options) WithLayout

func (o Options) WithLayout(layout LayoutType) Options

func (Options) WithOutputCSV

func (o Options) WithOutputCSV() Options

func (Options) WithPeriod

func (o Options) WithPeriod(period PeriodType) Options

func (Options) WithPretty

func (o Options) WithPretty() Options

func (Options) WithSortAmount

func (o Options) WithSortAmount() Options

func (Options) WithStartDate

func (o Options) WithStartDate(startDate string) Options

func (Options) WithTree

func (o Options) WithTree() Options

type PeriodType

type PeriodType string

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL