Initial setup

467 views
Skip to first unread message

o1bigtenor

unread,
Jul 7, 2014, 10:25:45 PM7/7/14
to ledge...@googlegroups.com
Greetings

Have got a (what seems to be working) copy of ledger 3.0 (on Debian Jessie).

I've used manual ledgers for lots of years and then rolled spreadsheets to work like a double entry record keeping system. I need something that works and will handle some complexity.

Ledger seems to be able to handle the complexity but its the simple stuff that I can't find any information on.

1. How do you set up that first ledger file? (No info in any of the docs)

I had over 200 accounts in my last spreadsheet journals and I would like to use even more and as I'm running a number of related small businesses things get interesting fast. More quiestions likely if I can get something setup.

Dee

Craig Earls

unread,
Jul 7, 2014, 10:27:32 PM7/7/14
to ledge...@googlegroups.com
Creating your ledger fe is as simple as creating a text file. The docs have example if what transactions look like. That's really it for basic setup. 
--

---
You received this message because you are subscribed to the Google Groups "Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ledger-cli+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--
Craig, Corona De Tucson, AZ
enderw88.wordpress.com

o1bigtenor

unread,
Jul 7, 2014, 10:35:39 PM7/7/14
to ledge...@googlegroups.com
On Mon, Jul 7, 2014 at 9:27 PM, Craig Earls <ende...@gmail.com> wrote:

Creating your ledger fe is as simple as creating a text file. The docs have example if what transactions look like. That's really it for basic setup.


tried a number of different commands and everything except the following said 'command not found'


ledger xact
Error: No journal file was specified (please use -f)

so this gets me somewhere but I'm still with 'how do I create a journal file?'.

Dee

Craig Earls

unread,
Jul 7, 2014, 10:37:32 PM7/7/14
to ledge...@googlegroups.com
You creat your journal with a text editor.  Emacs and vim are popular. Notepad would do in a pinch.  Enter you transaction in the text file then run the ledger program I that file. 


On Monday, July 7, 2014, o1bigtenor <o1big...@gmail.com> wrote:
--

---
You received this message because you are subscribed to the Google Groups "Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ledger-cli+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

o1bigtenor

unread,
Jul 7, 2014, 10:47:00 PM7/7/14
to ledge...@googlegroups.com
On Mon, Jul 7, 2014 at 9:37 PM, Craig Earls <ende...@gmail.com> wrote:
You creat your journal with a text editor.  Emacs and vim are popular. Notepad would do in a pinch.  Enter you transaction in the text file then run the ledger program I that file. 

I've used vim for editing but never for creating. Haven't ever used Emacs.

So what is the series of commands that are used to create a journal in ???????    ?

Dee

Craig Earls

unread,
Jul 7, 2014, 10:48:04 PM7/7/14
to ledge...@googlegroups.com
What OS  are you using?


On Monday, July 7, 2014, o1bigtenor <o1big...@gmail.com> wrote:
--

---
You received this message because you are subscribed to the Google Groups "Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ledger-cli+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

o1bigtenor

unread,
Jul 7, 2014, 10:54:31 PM7/7/14
to ledge...@googlegroups.com
On Mon, Jul 7, 2014 at 9:48 PM, Craig Earls <ende...@gmail.com> wrote:
What OS  are you using?

Debian Jessie (testing)

Craig Earls

unread,
Jul 7, 2014, 10:57:34 PM7/7/14
to ledge...@googlegroups.com
I don't have enough time right now to walk you through either editor.  I am partial to emacs and maintain the special helper software that makes maintains you ledger pretty easy. Google "emacs tutorial" and you will get scads of help. 

Please run"ledger --version". I don't know how up to date Debian is. 


On Monday, July 7, 2014, o1bigtenor <o1big...@gmail.com> wrote:
--

---
You received this message because you are subscribed to the Google Groups "Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ledger-cli+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Erik Hetzner

unread,
Jul 8, 2014, 12:56:03 AM7/8/14
to ledge...@googlegroups.com, o1bigtenor
At Mon, 7 Jul 2014 21:46:58 -0500,
o1bigtenor wrote:
>
> I've used vim for editing but never for creating. Haven't ever used Emacs.
>
> So what is the series of commands that are used to create a journal in
> ??????? ?

Hi Dee,

ledger never writes to your ledger file. Ledger is basically a
reporting system for plain text files that are in the ledger format.
You need to create your own ledger file from scratch. If you need help
creating and editing a plain text file on linux, there are probably
better places to look for that. If you can create a file, named
foo.lgr, in your home directory, that contains the following text:

2014/07/07 Initial
Equity -$100
Assets:Bank $100

then the command:

ledger -f ~/foo.lgr bal

should display your initial balance.

best, Erik

--
Sent from my free software system <http://fsf.org/>.

Simon Michael

unread,
Jul 8, 2014, 10:26:36 AM7/8/14
to ledge...@googlegroups.com
On 7/7/14 9:55 PM, Erik Hetzner wrote:
>> So what is the series of commands that are used to create a journal in
>> ??????? ?

hledger has an "add" command which can get you started without needing a
journal file or editor.

It will create whatever file you have defined in the LEDGER_FILE
environment variable, or ~/.hledger.journal. Ledger will use whatever
you have defined in LEDGER_FILE. So to make sure both tools see the same
file, you could do eg:

$ echo "export LEDGER_FILE=~/general.journal" >>~/.bashrc
$ source ~/.bashrc
$ hledger add
Date [2014/07/08]:
...
$ hledger print
...
$ ledger print
...




Martin Blais

unread,
Jul 8, 2014, 11:14:14 AM7/8/14
to ledger-cli
IMHO the presence of such a command defeats the purpose of creating a language in the first place.
If you can't edit a text file, you probably should not be using Ledger or Beancount.
I just can't imagine any realistic scenario where that ends in a happy story.
You won't be able to debug issues with the input without having a good handle on the file contents.
Suggesting such a user to rely on "ledger add" is not going to serve him well.

I'm not trying to be nasty... just realistic.
The whole point of creating a language is so that we don't have to have a UI.
My advice to the original user would be: go install some other software. Try GnuCash, get QuickBooks, etc.

o1bigtenor

unread,
Jul 8, 2014, 11:44:55 AM7/8/14
to ledge...@googlegroups.com



On Tue, Jul 8, 2014 at 10:14 AM, Martin Blais <bl...@furius.ca> wrote:
snip

I'm not trying to be nasty... just realistic.
The whole point of creating a language is so that we don't have to have a UI.
My advice to the original user would be: go install some other software. Try GnuCash, get QuickBooks, etc.

I'll start with the last stuff first.

I have tried to install GnuCash and the dependencies are legion and result in me not having a viable installation.
Tried Quickbooks and found that to get the level of detail that I wanted I would need to spend quite a bit of cash (IIRC I would need the 3rd or maybe even the fourth level of software and as all of the levels are in the software but only unlocked with greater fees I wasn't too terribly interested besides then I would be hostage to them forever for my information.).

I have tried a number of other OSS programs and the skills that I would take to install them were far beyond me and when I got the assistance of a friend (engineer type with 30 years of Unix/Linux experience) and STILL couldn't get things installed (with 50+ hours of time) I wasn't too terribly impressed. Software should be installable without needing 30 years of hacker experience to do so.

Then I found ledger CLI - - - seemed somewhat straightforward - - - - but  until Eric stated ". . . creating and editing a plain text file . . ." there was absolutely ZERO indication on how to start. Now if you know what you're doing man pages (as well as the vast majority of computer software documentation) are useful - - - if you don't (on the other hand) they don't serve ANY USEFUL PURPOSE!!

Something as basic as telling the user that you start with a text file and then edit it is very very simple - - - - its not in ANY of the documentation (I read each piece multiple times looking for a solution).
This kind of documentation reinforces my thinking that programmers should NEVER EVER be allowed to write documentation - - - they don't know how to. For that you need people who know nothing about your software and how to use it. Now when you have explained what to do to such a person they will have a way of writing the documentation - - - which ANYONE will understand.

But then I am assuming that you (the group) actually cares about those that would try to use the program. Comments like the last line above very much put the lie to that idea.

Dee

Craig Earls

unread,
Jul 8, 2014, 11:54:49 AM7/8/14
to ledge...@googlegroups.com
Dee,
  Please don't take offense. I am happy to help. But you caught me on a particularly bad day.  I have put a huge amount of time into the documentation and the emacs code to support editing ledger files and I always looking for ways to improve it. That said, for any tool there is a minimum required level of knowledge to use the tool. I would not expect some one who cannot balance a checkbook to understand how to use ledger. And I would not feel responsible to teach that so that they could use ledger.  I don't think it is appropriate to explain how to create a plain text file in the documentation any more than I am going to explain how to turn on the computer. 

I am interested in your perspectives on using ledger and will be happy to walk you through some basics. The learning curve will be steep. I can only really help in the evenings after I have taken care of worm and family.  
--

---
You received this message because you are subscribed to the Google Groups "Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ledger-cli+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

o1bigtenor

unread,
Jul 8, 2014, 12:10:28 PM7/8/14
to ledge...@googlegroups.com
On Tue, Jul 8, 2014 at 10:54 AM, Craig Earls <ende...@gmail.com> wrote:
Dee,
  Please don't take offense. I am happy to help. But you caught me on a particularly bad day.  I have put a huge amount of time into the documentation and the emacs code to support editing ledger files and I always looking for ways to improve it. That said, for any tool there is a minimum required level of knowledge to use the tool. I would not expect some one who cannot balance a checkbook to understand how to use ledger. And I would not feel responsible to teach that so that they could use ledger.  I don't think it is appropriate to explain how to create a plain text file in the documentation any more than I am going to explain how to turn on the computer. 

I was going to separate this into different sections but have decided not to.

That it is not necessary to indicate that one starts with a basic EMPTY text file is a huge hole in the documentation.
There is lots of detail for after that but NOTHING on that point. Yes it seems redundant now that I KNOW what is required it is quite different from every other program that I have run into or used.
The first request in most documentation is to start the program by using whatever has been designed to invoke said program.
Instead LedgerCLI asks you to edit a file as your first task.
Note there is nothing on a good place to place said file, what the file is or any other information.

Then you equate 'knowing' that a plain text file is needed with 'how to turn on the computer' - - - -
I don't think I need to tell you what kind of a response that should get. 

I am interested in your perspectives on using ledger and will be happy to walk you through some basics. The learning curve will be steep. I can only really help in the evenings after I have taken care of worm and family.  

We will see how things go.

Thanking you for your consideration.

Dee

Craig Earls

unread,
Jul 8, 2014, 12:23:15 PM7/8/14
to ledge...@googlegroups.com
Before we continue please remember that you paid nothing for this software. I have used ledger for four years now and this is the first time this question has been asked. I don't owe you anything. I will help but if you continue to write as if we do owe you then I am not interested.  And I do associate creating blank text files with turning on the computer. It is about all I could do with the Apple ][ I started with when I was 11. 


On Tuesday, July 8, 2014, o1bigtenor <o1big...@gmail.com> wrote:
--

---
You received this message because you are subscribed to the Google Groups "Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ledger-cli+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Martin Blais

unread,
Jul 8, 2014, 12:37:06 PM7/8/14
to ledger-cli
On Tue, Jul 8, 2014 at 11:44 AM, o1bigtenor <o1big...@gmail.com> wrote:
On Tue, Jul 8, 2014 at 10:14 AM, Martin Blais <bl...@furius.ca> wrote:
snip

I'm not trying to be nasty... just realistic.
The whole point of creating a language is so that we don't have to have a UI.
My advice to the original user would be: go install some other software. Try GnuCash, get QuickBooks, etc.

I'll start with the last stuff first.

I have tried to install GnuCash and the dependencies are legion and result in me not having a viable installation.
Tried Quickbooks and found that to get the level of detail that I wanted I would need to spend quite a bit of cash (IIRC I would need the 3rd or maybe even the fourth level of software and as all of the levels are in the software but only unlocked with greater fees I wasn't too terribly interested besides then I would be hostage to them forever for my information.).

Just curious, how much? 
I looked into it recently while doing research for my motivation document, and it seemed like 300$/year.
If you're not interested in development and instead want to just be a pure user of this, this is well spent money it IMO (although you're right that you're probably locking away your data in a silo... I wonder if QuickBooks has an open format export feature? I bet if probably does export to QBO files).


I have tried a number of other OSS programs and the skills that I would take to install them were far beyond me and when I got the assistance of a friend (engineer type with 30 years of Unix/Linux experience) and STILL couldn't get things installed (with 50+ hours of time) I wasn't too terribly impressed. Software should be installable without needing 30 years of hacker experience to do so.

Then I found ledger CLI - - - seemed somewhat straightforward - - - - but  until Eric stated ". . . creating and editing a plain text file . . ." there was absolutely ZERO indication on how to start. Now if you know what you're doing man pages (as well as the vast majority of computer software documentation) are useful - - - if you don't (on the other hand) they don't serve ANY USEFUL PURPOSE!!

Something as basic as telling the user that you start with a text file and then edit it is very very simple - - - - its not in ANY of the documentation (I read each piece multiple times looking for a solution).
This kind of documentation reinforces my thinking that programmers should NEVER EVER be allowed to write documentation - - - they don't know how to. For that you need people who know nothing about your software and how to use it. Now when you have explained what to do to such a person they will have a way of writing the documentation - - - which ANYONE will understand.

You're right, computer programmers do suck at writing prose. I don't think we should not be allowed to write documentation however, on the contrary, we should all start CARING MORE. Funny how timely you should be writing this now, I've been starting a "Getting Started" guide recently as part of my unfinished cookbook:

I'm working actively on this, hoping to get it finished within a few weeks.
Not sure it will help you much though, it's for Beancount syntax, not Ledger's. 
The ideas are very similar, but there are some subtle differences in semantics.

The hurdles you'll face with something like Ledger (or Beancount) are two-fold: first you'll face the hurdle of how to use the tools, which is what you're struggling with so far, and second, you'll face the hurdle of how to solve accounting problems with it, once you know the language. But in my opinion the command-line accounting community is still very much at an early and somewhat experimental stage when it comes to that and we aren't yet providing sufficient examples of how to solve problems. This is why I'm writing the cookbook: I want to share the methods I've come up with to solve all my accounting needs (and I pretty much have) and stimulate some discussion with others about how best to solve specific challenges. These days I'm writing documentation for that reason, isolating and discussing the various situations and solutions around many accounting problems. Ledger doesn't yet even book capital gains automatically (there is a pending patch that partially fixes that), and Beancount suffers from other shortcomings (inflexible filtering, inconsistent list of reports between web interface & console, and of course... no documentation... but I'm aiming to remedy all of that this summer, especially the documentation bit). 

Are you ready to participate in a construction project, or do you just want to get down to business without any bumps in the road at all?  If the former: Welcome to the community!  If the latter: my advice is save your time and go buy QuickBooks.



But then I am assuming that you (the group) actually cares about those that would try to use the program. Comments like the last line above very much put the lie to that idea.

Ok, so I can either lie and mislead you into thinking you can use our tools without editing text files and waste a whole bunch of your time until you realize for yourself that it won't work. Do you prefer that? Give it a shot... welcome to the Ledger user community! [*large embrace with arms wide open*]

Realistically, you probably need to be able to edit text files and be able to learn a very, very simple computer "language" if you're going to use this successfully. This is not me trying to put you off, I'm just saving you some pain, I'm stating a basic requirement of these command-line accounting tools. I'm just...  saying it like it is... we do it this way in order to _avoid_ user interfaces, because we think "language" is more powerful than menus and buttons and checkboxes. You made it sound like you did not expect to be editing text files.

Russell Adams

unread,
Jul 8, 2014, 2:07:03 PM7/8/14
to ledge...@googlegroups.com
In my experience ledger users should have the following skillset prior
to beginning with Ledger.

- Moderate to high skill with text file creation, management, and
organization as used a command line compilation and programming environments
- Basic version control knowledge
- Advanced command line facility
- Some prior programming experience regarding the idea of compiling
text files into reports, error message reporting and line numbering

I've tried to teach two bookkeepers to use Ledger and failed
miserably. They tried to use Windows tools like Notepad++ and scripts
I wrote for common reports. They couldn't grok the idea of having a
text data source and compiling reports from it. I feel your pain
having paid people for their time while I tried to teach them about
the tool I prefer.

If you already have these skills, Ledger has a gentle learning
curve. If you lack any, I would recommend commercial GUI software.

Thanks.
> > <javascript:_e(%7B%7D,'cvml','ledger-cli%2Bunsu...@googlegroups.com');>
> > .
> > For more options, visit https://groups.google.com/d/optout.
> >
>
>
> --
> Craig, Corona De Tucson, AZ
> enderw88.wordpress.com
>
> --
>
> ---
> You received this message because you are subscribed to the Google Groups "Ledger" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to ledger-cli+...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.


------------------------------------------------------------------
Russell Adams RLA...@AdamsInfoServ.com

PGP Key ID: 0x1160DCB3 http://www.adamsinfoserv.com/

Fingerprint: 1723 D8CA 4280 1EC9 557F 66E8 1154 E018 1160 DCB3

Craig Earls

unread,
Jul 8, 2014, 2:15:13 PM7/8/14
to ledge...@googlegroups.com
Tim,
   I will put that in the documentation. 

Craig. 

la...@larrystamm.com

unread,
Jul 8, 2014, 3:09:18 PM7/8/14
to ledge...@googlegroups.com
On 2014-07-08 12:10, o1bigtenor wrote:
>
>
> That it is not necessary to indicate that one starts with a basic EMPTY
> text file is a huge hole in the documentation.
> There is lots of detail for after that but NOTHING on that point. Yes
> it
> seems redundant now that I KNOW what is required it is quite different
> from
> every other program that I have run into or used.

I am mostly a lurker here, but I must respond to this. Right on the
home page of ledger-cli.org it says:

----------------------------------------------------------------------
Welcome to ledger

Ledger is a powerful, double-entry accounting system that is accessed
from the UNIX command-line. Ledger, begun in 2003, is written by John
Wiegley and released under the BSD license. It has also inspired several
ports to other languages.

To get started with Ledger, add transactions to a text file in Ledger’s
own textual format. Here’s what a single transaction might look like:

2006/10/15 Exxon
Expenses:Auto:Gas $10.00
Liabilities:MasterCard $-10.00

You use the ledger command line program to see the balance of your
accounts:

$ ledger -f your-file.dat balance
$10.00 Expenses:Auto:Gas
$-10.00 Liabilities:MasterCard
--------------------
0

or the history of a particular account:

$ ledger -f your-file.dat register Expenses

06-Oct-15 Exxon Expenses:Auto:Gas $10.00
$10.00

-----------------------------------------------------------------------------------

If that is not a clear and succinct description of how to use ledger
then what is it?
It certainly says right up front that you need to add transactions to a
text file in a certain format and then gives examples of that format.

> The first request in most documentation is to start the program by
> using
> whatever has been designed to invoke said program.

Isn't that information right there?

> Instead LedgerCLI asks you to edit a file as your first task.
> Note there is nothing on a good place to place said file, what the file
> is
> or any other information.
>

Where to put the data file, and what to name it, is totally up to the
user's preference and is part of the attraction of ledger for those that
use it.

> Then you equate 'knowing' that a plain text file is needed with 'how to
> turn on the computer' - - - -
> I don't think I need to tell you what kind of a response that should
> get.
>

If turning on a computer is not equivalent to having a text editor and
command line to use, then unless you are wanting to face the steep
learning curve involved in learning ledger and a text editor and a
command line all at the same time, you are probably better off with some
other accounting software (as others have already stated). This is not
being mean and nasty, it just is how it is. I have tried to teach other
people to use ledger, and only the ones who were already emacs users
grasped it.

And no, I am not a programmer. But I started using a computer with a
text editor and command prompt, so using ledger seems natural.

Martin Blais

unread,
Jul 8, 2014, 3:29:23 PM7/8/14
to ledger-cli
On Tue, Jul 8, 2014 at 2:07 PM, Russell Adams <RLA...@adamsinfoserv.com> wrote:
In my experience ledger users should have the following skillset prior
to beginning with Ledger.

 - Moderate to high skill with text file creation, management, and
   organization as used a command line compilation and programming environments
 - Basic version control knowledge

You don't need VC knowledge. 
Imagine a user that just makes backups by copying files manually, totally fine.
Perhaps unwise, but still.

Simon Michael

unread,
Jul 12, 2014, 12:04:05 PM7/12/14
to ledge...@googlegroups.com
Hi Dee,

You're not alone! When I first took the plunge with Ledger, I had
exactly the same problem. I'm a programmer, and very comfortable with
editing text files. But it wasn't obvious how exactly to get started.
Like you, I found this to be a hole in the documentation/command-line
help/feature set. It wasn't that hard to figure out, but I shouldn't
have had to work at it.

http://ledger-cli.org now exists, and seems clear enough. But things
should be intuitive even without that, eg from the command-line help or
error messages or commands. (hledger's add command exists for this
reason, among others).

Reply all
Reply to author
Forward
0 new messages