Skip to content

A simple tool for automatically generating monthly invoices. No need to fill anything out each month, you set it up once, and it works.

License

Notifications You must be signed in to change notification settings

sesav/invoice-generator

Repository files navigation

Invoice-generator

Invoice-generator is a simple tool for automatically generating invoices. No need to fill anything out every month, you set it up once, and it works.

It can be used for multiple projects simultaneously: just create different configuration files and place them in separate folders where you want the invoices to be saved.

Installation

Binaries

Pre-built binaries

Download the binary file for your platform, copy it to /usr/local/bin, and give execute permission. Here is an example of my configuration for Linux:

sudo wget https://github.com/sesav/invoice-generator/releases/latest/download/invoice-generator.linux-amd64 -O /usr/local/bin/invoice-generator
sudo chmod +x /usr/local/bin/invoice-generator

And for MacOS:

sudo wget https://github.com/sesav/invoice-generator/releases/latest/download/invoice-generator.darwin-arm64 -O /usr/local/bin/invoice-generator
sudo chmod +x /usr/local/bin/invoice-generator

Build from source

Clone the repo:

git clone https://github.com/sesav/invoice-generator.git

Install just command runner, then run:

just install

You can also build for all platforms:

just build

Configuration

If you run the invoice generation for the first time without an invoice-generator.toml file in the directory, the program will ask you a question:

The file invoice-generator.toml was not found in the current directory. Want to create it? (Y/n)

Type Y, then open the generated invoice-generator.toml file and fill in your invoice parameters. Once this is done, the configuration setup is complete and you can start generating invoices.

General usage

To generate a new invoice, run the following command:

invoice-generator g

In addition, you can specify the date (month.year) of the desired service period as an argument, as follows:

invoice-generator g 10.2023

You will receive an invoice for the desired period (for example, the previous month) with the correct dates in all relevant fields.

Help information

$ invoice-generator
NAME:
   invoice-generator - cli invoice assistant

USAGE:
   invoice-generator [global options] command [command options] [arguments...]

VERSION:
   0.9

DESCRIPTION:
   This is a simple tool for automatically generating invoices. No need to fill anything out every month, you set it up once, and that's it.

COMMANDS:
   generate, g  Generate a new invoice based on the information in invoice-generator.toml and the current date.
                Alternatively, you can provide the date (month.year) for the desired service period as an argument, like this: invoice-generator g 10.2023

   help, h      Show a list of commands or help for a specific command.

GLOBAL OPTIONS:
   --help, -h     show help
   --version, -v  print the version

Invoice example:

Requirements

There are no requirements or additional dependencies, it works on Windows, Linux, and macOS.

License

Open sourced under the MIT license.

About

A simple tool for automatically generating monthly invoices. No need to fill anything out each month, you set it up once, and it works.

Topics

Resources

License

Stars

Watchers

Forks