Hello Mortimer,

I really like your approach as it is simple and does exactly what I want it 
to do. In addition to what you've written here, I got it to play nice with 
ledger-report-mode by customizing the `ledger-reports` variable as follows:

    (setq ledger-reports
          '(("bal" "gpg --no-tty -d %(ledger-file) | ledger -f - bal")
            ("reg" "gpg --no-tty -d %(ledger-file) | ledger -f - reg")
            ("payee" "gpg --no-tty -d %(ledger-file) ledger -f - reg 
@%(payee)")
            ("account" "gpg --no-tty -d %(ledger-file) | ledger -f - reg 
%(account)")))

Hope this helps!

/vedang

On Wednesday, February 16, 2011 at 3:22:48 PM UTC+5:30, Mortimer wrote:
>
> hi all, 
>
> I am still new to ledger, but I wanted to explain how I do encryption 
> of the journal and maybe get some input from you all. 
>
> So, I have one ledger file that I share between computers with 
> Dropbox. Mainly one computer at home running OSX and one at work with 
> Ubuntu. The journal is in a directory in Dropbox, encrypted 
> symetrically with gpg. 
>
> I use Emacs to edit the file and org-capture to enter entries quickly, 
> with easypg (http://www.emacswiki.org/emacs/EasyPG), Emacs deals 
> transparently with the encryption, so it asks for the keyphrase when I 
> try to enter a new entry via org-capture or when I open the file. 
>
> ledger-report mode gets confused with this setup and  I haven't yet 
> found how to get it to work nice with it. In the meantime, I use it 
> from the command line, what I do is: 
>
> > gpg -d pathtomyjournal.gpg | ledger -f - any following arguments 
>
> I have done an alias to have this available quickly: 
>
> alias gledger='gpg -d pathtotheledger | ledger -f -' 
>
> I can then do simple things like: 
>
> gledger bal 
> gledger reg 
> etc. 
>
> I will be prompted for the password and then see the report. 
>
> Some drawbacks of this setup: 
>   - I still have to get the report-mode in emacs to play nice with 
> this 
>   - on the OS X machine, I have Ledger 3 and it seems to get sometimes 
> confused with the command line parameters in this setup 
>   - as you get the file from the standard input, the ledger commands 
> for writing in the file will be confused. 
>

-- 

--- 
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 [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to