a combined quick reference, aka "rosetta stone"
Covers the essentials of Ledger/hledger/Beancount journal format. The master copy is in google docs for easier table editing, but this will likely change in future.
This commit is contained in:
19
Makefile
19
Makefile
@@ -1,7 +1,9 @@
|
|||||||
all: $(patsubst %.md,%.html,$(wildcard *.md)) Makefile
|
all: mdtohtml
|
||||||
|
|
||||||
|
mdtohtml: $(patsubst %.md,%.html,$(wildcard *.md)) Makefile
|
||||||
|
|
||||||
watch:
|
watch:
|
||||||
fswatch -0 *.{md,tmpl} | xargs -0 -n1 -I{} make all
|
fswatch -l 0.1 -0 *.{md,tmpl} | xargs -0 -n1 -I{} make all
|
||||||
|
|
||||||
livereload:
|
livereload:
|
||||||
livereloadx -p 10000 --static .
|
livereloadx -p 10000 --static .
|
||||||
@@ -17,3 +19,16 @@ PANDOC = pandoc # --from markdown --to html
|
|||||||
%.html: %.md index.tmpl
|
%.html: %.md index.tmpl
|
||||||
$(PANDOC) --template index.tmpl $< -o $@
|
$(PANDOC) --template index.tmpl $< -o $@
|
||||||
|
|
||||||
|
quickref/index.html:
|
||||||
|
rm -rf quickref/QuickReferencefortheLedger-Likes
|
||||||
|
-mv ~/Desktop/QuickReferencefortheLedger-Likes quickref
|
||||||
|
cp quickref/QuickReferencefortheLedger-Likes/images/* quickref/images
|
||||||
|
cp quickref/QuickReferencefortheLedger-Likes/QuickReferencefortheLedgerLikes.html quickref/index.html
|
||||||
|
perl -p -i -e 's%<style.*</style>%<meta name="viewport" content="width=device-width, initial-scale=1"><link href="//fonts.googleapis.com/css?family=Raleway:400,300,600" rel="stylesheet" type="text/css"><link rel="stylesheet" href="css/normalize.css"><link rel="stylesheet" href="css/skeleton.css"><link rel="stylesheet" href="css/site.css"><link rel="icon" type="image/png" href="images/favicon.png"><link href="quickref.css" rel="stylesheet">%' $@
|
||||||
|
perl -p -i -e 's/>/>\n/g' $@
|
||||||
|
perl -p -i -e 's/(<body .*)/\1\n<div class="container">/' $@
|
||||||
|
perl -p -i -e 's/<\/body>/<\/div>\n<\/body>/' $@
|
||||||
|
|
||||||
|
# XXX not working
|
||||||
|
# watch-quickref:
|
||||||
|
# fswatch -l 0.1 -0 ~/Desktop/QuickReferencefortheLedger-Likes/QuickReferencefortheLedgerLikes.html | xargs -0 -n1 -I{} cat #echo make quickref.html
|
||||||
|
|||||||
11
quickref/a.beancount
Normal file
11
quickref/a.beancount
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
2016-01-01 open Assets:Checking
|
||||||
|
2016-01-01 open Equity:Opening-Balances
|
||||||
|
2016-01-01 open Expenses:Groceries
|
||||||
|
|
||||||
|
2016-01-01 txn "set opening balance"
|
||||||
|
Assets:Checking 1.000,0001USD
|
||||||
|
Equity:Opening-Balances
|
||||||
|
|
||||||
|
2016/1/5 txn "farmer's market"
|
||||||
|
Expenses:Groceries 50 USD
|
||||||
|
Assets:Checking
|
||||||
7
quickref/a.hledger
Normal file
7
quickref/a.hledger
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
2016/1/1 set opening balance
|
||||||
|
assets:checking $500.00
|
||||||
|
equity:opening balances
|
||||||
|
|
||||||
|
2016/1/5 farmer's market
|
||||||
|
expenses:groceries $50.00
|
||||||
|
assets:checking
|
||||||
7
quickref/a.ledger
Normal file
7
quickref/a.ledger
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
2016/1/1 set opening balance
|
||||||
|
assets:checking $500.00
|
||||||
|
equity:opening balances
|
||||||
|
|
||||||
|
2016/1/5 farmer's market
|
||||||
|
expenses:groceries $50.00
|
||||||
|
assets:checking
|
||||||
0
quickref/images/.gitkeep
Normal file
0
quickref/images/.gitkeep
Normal file
1105
quickref/index.html
Executable file
1105
quickref/index.html
Executable file
File diff suppressed because it is too large
Load Diff
41
quickref/quickref.css
Normal file
41
quickref/quickref.css
Normal file
@@ -0,0 +1,41 @@
|
|||||||
|
tr {
|
||||||
|
vertical-align:top;
|
||||||
|
}
|
||||||
|
/* TOC */
|
||||||
|
/* update these class ids on each save */
|
||||||
|
p { margin:0; }
|
||||||
|
p.c37 { visibility:hidden; }
|
||||||
|
p.c26 { margin-left:1em; }
|
||||||
|
p.c24 { margin-left:3em; }
|
||||||
|
p.c19 { margin-left:2em; }
|
||||||
|
/* heading cells */
|
||||||
|
tr:first-child {
|
||||||
|
font-weight:bold;
|
||||||
|
}
|
||||||
|
td:first-child {
|
||||||
|
/* font-weight:bold; */
|
||||||
|
}
|
||||||
|
tr:first-child a {
|
||||||
|
font-size:small;
|
||||||
|
/* white-space:nowrap; */
|
||||||
|
}
|
||||||
|
td:first-child {
|
||||||
|
width:10%;
|
||||||
|
}
|
||||||
|
/* body cells */
|
||||||
|
tr:not(:first-child) td:not(:first-child) span:first-child {
|
||||||
|
white-space:nowrap;
|
||||||
|
font-weight:bold;
|
||||||
|
color:navy;
|
||||||
|
font-family:monospace;
|
||||||
|
/* font-family:monaco; */
|
||||||
|
/* font-size:small; */
|
||||||
|
}
|
||||||
|
tr:not(:first-child) td:not(:first-child) span:not(:first-child) {
|
||||||
|
/* white-space:nowrap; */
|
||||||
|
/* font-family:monospace; */
|
||||||
|
font-size:small;
|
||||||
|
}
|
||||||
|
td:not(:first-child) {
|
||||||
|
width:30%;
|
||||||
|
}
|
||||||
11
quickref/tests.shelltest
Executable file
11
quickref/tests.shelltest
Executable file
@@ -0,0 +1,11 @@
|
|||||||
|
#!/usr/bin/env shelltest
|
||||||
|
# -*- sh -*-
|
||||||
|
|
||||||
|
ledger -f a.ledger print
|
||||||
|
>>>=0
|
||||||
|
|
||||||
|
hledger -f a.hledger print
|
||||||
|
>>>=0
|
||||||
|
|
||||||
|
beancount -f a.beancount print
|
||||||
|
>>>=0
|
||||||
Reference in New Issue
Block a user