This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env stack | |
{- stack --resolver=lts-9.21 script --compile | |
--package "bytestring cassava gogol gogol-core gogol-sheets lens pretty-show text" | |
--verbosity=info | |
-} | |
{- | |
INSTALL: | |
Get stack if needed, eg from https://haskell-lang.org/get-started | |
Run "get-google-sheet-csv.hs" once to compile. On Windows, run "stack get-googlesheet-csv.hs". |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ledger-analytics$ git diff analyze.js | |
diff --git a/analyze.js b/analyze.js | |
index 09a98dd..34eefcd 100644 | |
--- a/analyze.js | |
+++ b/analyze.js | |
@@ -2,7 +2,7 @@ const util = require('util') | |
const exec = util.promisify(require('child_process').exec) | |
module.exports.getCommodities = async (file) => { | |
- const { stdout } = await exec('ledger -f ' + file + ' commodities') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias /^income/ = revenues | |
include 2012.journal | |
include 2013.journal | |
end aliases |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# XpenseTracker iOS app -> hledger import & reports | |
# | |
# Fetch csv files from XpenseTracker iphone app (requires curl, funzip). | |
# Procedure: | |
# connect phone and computer to same network | |
# make csv | |
# start XpenseTracker app | |
# enter each XpenseTracker log, as prompted on computer | |
# (first time: options, set appropriate CSV fields) | |
# options, export, export |
next time, we could set up a shared branch in main repo - simpler workflows, writable by all collaborators
<virkony> sm: recently I’ve noticed that hledger repo have option “Create a merge commit” for pull-request disabled. Is that default settings or you configured that?
configured it, generally I like to have clean-ish rebased commits in master
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
old: | |
* Budgeting and forecasting document | |
* Show percentage of budget spent | |
* --budget switch for "balance" | |
* added --auto to balancemode, print, register | |
* added --forecast to balancemode, print, register | |
* Make runPeriodicTransaction stricter: it will reject period start days that do not line up with requested interval. This is very helpful for periodic transactions, because in budget mode you need to ensure that no periodic transactions extend past the end of the journal, and in forecast mode you need to make sure that all periodic transactions are strictly after the end of the journal. | |
* ensure that runPeriodicTransaction does not generate transactions outside of the requested DateSpan | |
* More AutoTransaction tests. Some of them demonstrate that runPeriodicTransaction could generate transactions ouside of requested DateSpan. This happens because runPeriodicTransaction uses splitSpan internally, and splitSpan always generates dateSpans that fully cover original DateSpan, extending beyound left/right boundar |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--alias=/:(business|personal):/=: | |
--alias=/:(bank|cash|online):/=: | |
--alias=/:bofi:/=:b | |
--alias=/:unify:/=:u | |
--alias=/:wf:/=:w | |
cur:. | |
-2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Thu Oct 12 2017] | |
<immae> Hey all! I'm facing a tricky situation with ledger: https://paste.ee/p/BNWVU Any hint? | |
[02:03] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PERIOD ACCT AMT | |
PERIOD | |
ACCT1 AMT1 | |
... | |
# setting time target for "admin" activities | |
2016y adm 240 | |
2016q4 adm 60 |