Re: ledger2beancount: ledger to beancount converter

2018-03-31 Thread Scott Carpenter
I love this discussion! I think I sounded more sour on beancount than was 
warranted -- I'm also excited about the community around ledger and plain 
text accounting and that people are making other tools. And as someone who 
loves Python and is writing my own helpers for ledger, I should be looking 
at beancount to learn things! (Currently I'm working on a qif importer to 
bring in 12 years of MS Money data and 5 years of KMyMoney.)

I suspect I have little to worry about with long term ledger maintenance -- 
I use a fairly small set of features for my personal finances.

As for the spaces, I could probably adapt to dashes, but I like the 
readability with spaces, even using them after colons, e.g.:

2017/11/30 johnny paycheck
i: wages: gross pay $-2,100
i: wages: employer match$-63
e: taxes: federal   $171.46
e: taxes: state $126.66
e: taxes: social security   $130.2
e: taxes: medicare  $30.45
e: healthcare: medical insurance$231.89
a: 401k: cash   ($126 + $63)
a: fsa  $41.67
a: checking $1,241.67

Using Sublime Text I've even gone all in with syntax highlighting. (Which 
isn't space related, of course.) :-)




On Saturday, March 31, 2018 at 3:13:09 AM UTC-5, Martin Michlmayr wrote:
>
> * Stefano Zacchiroli  [2018-03-31 10:02]: 
> > Maybe you can elaborate on why not supporting spaces in account names 
> > bothered you? I also had to migrate to '-' as I had spaces in my Ledger 
> > account names, but in the end I realized dashes are better anyway: they 
> > don't get in the way of dumb text processing of your ledger, like grep, 
> > sed, and the like. Just curious :) 
>
> I can't speak for Scott but I think it's just what you're used to. 
> I'm slowly getting used to the dashes and, as you say, they make 
> parsing and stuff easier.  But "Liabilities:Credit-Card" looks weird 
> when you're used to "Liabilities:Credit Card".  I'm sure I will get 
> used to it in a few weeks though. 
>
> In general, ledger is *extremely* permissive in what it allows.  For 
> example, Assets:♚_DASD!;?@#$!%^& *"(*(0-;♚ds is a perfectly valid 
> account name in ledger.  So I believe people moving from ledger to 
> beancount might feel restricted in what they can do. 
>
> Then again, I'm using the opportunity to clean up my account and 
> commodity names, for example moving from "M" in ledger to MILESMORE 
> in beancount.  It will take some time getting used to the new names 
> but in general I think I'll prefer them more longterm (quoted 
> commodities in ledger are not ideal anyway because you have to 
> double-quote them). 
>
> -- 
> Martin Michlmayr 
> http://www.cyrius.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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: ledger2beancount: ledger to beancount converter

2018-03-31 Thread Martin Michlmayr
* Stefano Zacchiroli  [2018-03-31 10:02]:
> Maybe you can elaborate on why not supporting spaces in account names
> bothered you? I also had to migrate to '-' as I had spaces in my Ledger
> account names, but in the end I realized dashes are better anyway: they
> don't get in the way of dumb text processing of your ledger, like grep,
> sed, and the like. Just curious :)

I can't speak for Scott but I think it's just what you're used to.
I'm slowly getting used to the dashes and, as you say, they make
parsing and stuff easier.  But "Liabilities:Credit-Card" looks weird
when you're used to "Liabilities:Credit Card".  I'm sure I will get
used to it in a few weeks though.

In general, ledger is *extremely* permissive in what it allows.  For
example, Assets:♚_DASD!;?@#$!%^& *"(*(0-;♚ds is a perfectly valid
account name in ledger.  So I believe people moving from ledger to
beancount might feel restricted in what they can do.

Then again, I'm using the opportunity to clean up my account and
commodity names, for example moving from "M" in ledger to MILESMORE
in beancount.  It will take some time getting used to the new names
but in general I think I'll prefer them more longterm (quoted
commodities in ledger are not ideal anyway because you have to
double-quote them).

-- 
Martin Michlmayr
http://www.cyrius.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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: ledger2beancount: ledger to beancount converter

2018-03-31 Thread Stefano Zacchiroli
On Sat, Mar 31, 2018 at 09:59:46AM +0200, Martin Michlmayr wrote:
> * Scott Carpenter  [2018-03-30 16:32]:
> > I looked briefly at BeanCount but seem to recall being turned off by
> > things like not allowing spaces in account names?

Maybe you can elaborate on why not supporting spaces in account names
bothered you? I also had to migrate to '-' as I had spaces in my Ledger
account names, but in the end I realized dashes are better anyway: they
don't get in the way of dumb text processing of your ledger, like grep,
sed, and the like. Just curious :)

Cheers
-- 
Stefano Zacchiroli . z...@upsilon.cc . upsilon.cc/zack . . o . . . o . o
Computer Science Professor . CTO Software Heritage . . . . . o . . . o o
Former Debian Project Leader . OSI Board Director  . . . o o o . . . o .
« the first rule of tautology club is the first rule of tautology club »

-- 

--- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: ledger2beancount: ledger to beancount converter

2018-03-31 Thread Martin Michlmayr
* Scott Carpenter  [2018-03-30 16:32]:
> I looked 
> briefly at BeanCount but seem to recall being turned off by things like not 
> allowing spaces in account names?

That's correct, spaces are not allowed in beancount account names.
You can use dash instead.

Beancount is more restrictive than ledger (e.g. dates have to be in
-MM-DD) format but the syntax is also cleaner in some ways (#tags
for tags) and has some nice features (^links can be used to link
different transactions together; differentiation between payee and a
description called "narration").

-- 
Martin Michlmayr
http://www.cyrius.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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: ledger2beancount: ledger to beancount converter

2018-03-31 Thread John Wiegley
> "SC" == Scott Carpenter  writes:

SC> Well I don't have any preference for which format of ledger lives on, be
SC> it C++ or Haskell or whatever, but I certainly hope that something will be
SC> maintained long term that supports the classic ledger file. I looked
SC> briefly at BeanCount but seem to recall being turned off by things like
SC> not allowing spaces in account names? (Was going to double-check but can't
SC> seem to load its web page right now.)

Do note that I'll always be using Ledger throughout my life, so it will always
be capable of running on the computers I use, and performing the reports that
I create. I can't promise much development work beyond that, as my interests
have run quite far afield from C++ these days.

Beancount and hledger are fantastic pieces of work, and I'm very glad for the
enthusiasm and energy Martin and Simon have put into them. It ensures the
Ledger idea will survive my lack of free time. I encourage everyone whose
needs are met by those variants to give them a try, and see if it better
satisfies your accounting needs.

Meanwhile, those who are happy with C++Ledger in its current form are welcome
to join me through the coming years, for what I intend to become an extremely
stable code base. :)

John

-- 

--- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: ledger2beancount: ledger to beancount converter

2018-03-30 Thread Scott Carpenter
Well I don't have any preference for which format of ledger lives on, be it 
C++ or Haskell or whatever, but I certainly hope that something will be 
maintained long term that supports the classic ledger file. I looked 
briefly at BeanCount but seem to recall being turned off by things like not 
allowing spaces in account names? (Was going to double-check but can't seem 
to load its web page right now.)

Scott

On Friday, March 30, 2018 at 10:01:36 AM UTC-5, Martin Michlmayr wrote:
>
> * Marcin Borkowski  [2018-03-30 16:15]: 
> > That sounds interesting.  I have one question: why would I want to 
> > migrate to beancount? 
> > 
> > Actually, one possible answer is the existence of a Web UI 
>
> I'm a command-line person myself and use ledger reg and bal all the 
> time and I was completely surprised by how much I like the web UI.  It 
> makes things so much simpler.  I can click on some account names and 
> navigate around very easily.  And it offers charts, so I can actually 
> *see* what's going on.  It's very interesting to see the pattern on 
> some accounts (e.g. the spike once a month when your salary comes in, 
> or the spike in the other direction when you pay rent ;)  And money 
> coming into a pension and then being invested a few days later). 
> Fava doesn't do everything I want yet but the developers are *very* 
> responsive. 
>
> I don't know what Emacs' ledger-mode is like, but compared to the 
> command-line I really love the web UI.  And you can still do 
> command-line stuff in bean-count since it has a powerful SQL-inspired 
> language. 
>
> Anyway, I think it's a personal choice, but there are a number of 
> reasons I'm in the process of moving from ledger to beancount: 
>
> * Python interface: beancount has a powerful Python interface, so you 
>   can do interesting things with your data.  Ledger has a very basic 
>   Python interface and I've been waiting for years for it to get 
>   better but nobody is working on it. 
> * Written in Python: this makes it more likely I can fix bugs myself 
> * More maintained: John has done a fantastic job creating ledger but 
>   he's very clear that he has little interest in working on the C++ 
>   code base.  Martin Blais (the maintainer of beancount) is quite busy 
>   too but I think there's more chance of a community forming around 
>   beancount. 
> * Web UI (fava), truly the "killer app" for beancount 
> * Great documentation 
> * Great design (clear data structures, solid documentation, cleare 
>   syntax, etc) 
>
> Again, ledger is fantastic.  I've used it since 2010 and I'm very 
> grateful to John for creating ledger and introducing the idea of 
> text-based accounting.  But from my POV, beancount is the way forward 
> and I intend to focus my efforts there. 
>
> -- 
> Martin Michlmayr 
> http://www.cyrius.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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: ledger2beancount: ledger to beancount converter

2018-03-30 Thread Martin Michlmayr
* Marcin Borkowski  [2018-03-30 16:15]:
> That sounds interesting.  I have one question: why would I want to
> migrate to beancount?
> 
> Actually, one possible answer is the existence of a Web UI

I'm a command-line person myself and use ledger reg and bal all the
time and I was completely surprised by how much I like the web UI.  It
makes things so much simpler.  I can click on some account names and
navigate around very easily.  And it offers charts, so I can actually
*see* what's going on.  It's very interesting to see the pattern on
some accounts (e.g. the spike once a month when your salary comes in,
or the spike in the other direction when you pay rent ;)  And money
coming into a pension and then being invested a few days later).
Fava doesn't do everything I want yet but the developers are *very*
responsive.

I don't know what Emacs' ledger-mode is like, but compared to the
command-line I really love the web UI.  And you can still do
command-line stuff in bean-count since it has a powerful SQL-inspired
language.

Anyway, I think it's a personal choice, but there are a number of
reasons I'm in the process of moving from ledger to beancount:

* Python interface: beancount has a powerful Python interface, so you
  can do interesting things with your data.  Ledger has a very basic
  Python interface and I've been waiting for years for it to get
  better but nobody is working on it.
* Written in Python: this makes it more likely I can fix bugs myself
* More maintained: John has done a fantastic job creating ledger but
  he's very clear that he has little interest in working on the C++
  code base.  Martin Blais (the maintainer of beancount) is quite busy
  too but I think there's more chance of a community forming around
  beancount.
* Web UI (fava), truly the "killer app" for beancount
* Great documentation
* Great design (clear data structures, solid documentation, cleare
  syntax, etc)

Again, ledger is fantastic.  I've used it since 2010 and I'm very
grateful to John for creating ledger and introducing the idea of
text-based accounting.  But from my POV, beancount is the way forward
and I intend to focus my efforts there.

-- 
Martin Michlmayr
http://www.cyrius.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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: ledger2beancount: ledger to beancount converter

2018-03-30 Thread Marcin Borkowski

On 2018-03-30, at 14:17, Martin Michlmayr  wrote:

> I'd like to announce ledger2beancount, a script to convert ledger
> files to beancount.  It was developed by Stefano Zacchiroli and
> myself.

That sounds interesting.  I have one question: why would I want to
migrate to beancount?

Actually, one possible answer is the existence of a Web UI - while I'm
perfectly happy with Emacs' ledger-mode, I'm considering teaching some
basics of accounting to my 8-yo daughter, and I'm not sure how she would
react to Emacs. :-P

But I'm curious about a comparison.

Best,

-- 
Marcin Borkowski
http://mbork.pl

-- 

--- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


ledger2beancount: ledger to beancount converter

2018-03-30 Thread Martin Michlmayr
I'd like to announce ledger2beancount, a script to convert ledger
files to beancount.  It was developed by Stefano Zacchiroli and
myself.

ledger2beancount supports the majority of ledger syntax and features.
It also includes some features to improve the conversion from ledger
to beancount.  For example, ledger only offers one payee field which
can be used for the payee or as a free-form description of the
transaction.  Beancount has two fields, payee and narration.
ledger2beancount has two configurable mechanisms that let you
determine the payee from the narration (ledger's payee field).

You can obtain ledger2beancount from
https://github.com/zacchiro/ledger2beancount/

The supported ledger features are described in the README and there's
a manual with detailed descriptions of ledger2beancount's features.
There's also an illustrated example showing some of the differences
between ledger and beancount.

Martin Blais released beancount 2.0 a few days ago, so this is a good
time to give it a go.  In addition to beancount, you may be interested
in fava, a web UI for beancount.

Feedback and improvements to ledger2beancount are welcome (see the
contribution information).

Martin & Zack

Links:

* ledger2beancount: https://github.com/zacchiro/ledger2beancount/
* beancount: http://furius.ca/beancount/
* fava: https://beancount.github.io/fava/

-- 
Martin Michlmayr
http://www.cyrius.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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.