From 87860903f748ffc0be99488995d8b7578dd6fb8b Mon Sep 17 00:00:00 2001 From: Aaron Fiore Date: Tue, 26 Mar 2024 23:43:34 -0700 Subject: [PATCH 1/4] hledger-flow: electrum: clarify SPEND comment --- .../src/hledger-flow/accounts/electrum/electrum-shared.rules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/container/src/hledger-flow/accounts/electrum/electrum-shared.rules b/container/src/hledger-flow/accounts/electrum/electrum-shared.rules index 72f6819..70eeea1 100644 --- a/container/src/hledger-flow/accounts/electrum/electrum-shared.rules +++ b/container/src/hledger-flow/accounts/electrum/electrum-shared.rules @@ -76,6 +76,6 @@ if %direction ^OUT$ amount4 %fee BTC comment txid:%txid, notes:%label, taxed_as:SPEND comment3 %timestamp,SPEND,electrum,BTC,%fee,USD,%fiat_fee,FEE -# comment3 so account2 SPEND isn't overwritten, when applicable +# Using comment3 so a comment2 SPEND isn't overwritten (when applicable) # vim: sw=2 sts=2 si ai et From 5d0942e9e0623a5040e09a271c8998dd94e406e3 Mon Sep 17 00:00:00 2001 From: Aaron Fiore Date: Wed, 27 Mar 2024 00:13:59 -0700 Subject: [PATCH 2/4] hledger-flow: electrum: add subaccount to applicable memos --- .../hledger-flow/accounts/electrum/electrum-shared.rules | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/container/src/hledger-flow/accounts/electrum/electrum-shared.rules b/container/src/hledger-flow/accounts/electrum/electrum-shared.rules index 70eeea1..3a2b7d4 100644 --- a/container/src/hledger-flow/accounts/electrum/electrum-shared.rules +++ b/container/src/hledger-flow/accounts/electrum/electrum-shared.rules @@ -48,13 +48,13 @@ if %direction ^IN$ if %direction ^IN$ & %label Gift account2 income:electrum:%subaccount:gifts:BTC - comment2 %timestamp,GIFTIN,electrum,BTC,%value_without_fee,USD,%fiat_value,Unknown + comment2 %timestamp,GIFTIN,electrum,BTC,%value_without_fee,USD,%fiat_value,To %subaccount # OUT if %direction ^OUT$ account2 expenses:electrum:%subaccount:BTC - comment2 %timestamp,SPEND,electrum,BTC,%value_without_fee,USD,, + comment2 %timestamp,SPEND,electrum,BTC,%value_without_fee,USD,,From %subaccount if %direction ^OUT$ & %label (Self|Equity transfer|Capital contribution) @@ -65,7 +65,7 @@ if %direction ^OUT$ if %direction ^OUT$ & %label Gift account2 expenses:electrum:%subaccount:gifts:BTC - comment2 %timestamp,GIFT,electrum,BTC,%value_without_fee,USD,%fiat_value,Unknown + comment2 %timestamp,GIFT,electrum,BTC,%value_without_fee,USD,%fiat_value,From %subaccount # Fees if %direction ^OUT$ From 5951faf1da556554652e5465f71a5dff6ccbe9b2 Mon Sep 17 00:00:00 2001 From: Aaron Fiore Date: Wed, 27 Mar 2024 00:20:48 -0700 Subject: [PATCH 3/4] hledger-flow: electrum: add fiat_value to all outgoing expenses --- .../src/hledger-flow/accounts/electrum/electrum-shared.rules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/container/src/hledger-flow/accounts/electrum/electrum-shared.rules b/container/src/hledger-flow/accounts/electrum/electrum-shared.rules index 3a2b7d4..1ec4b93 100644 --- a/container/src/hledger-flow/accounts/electrum/electrum-shared.rules +++ b/container/src/hledger-flow/accounts/electrum/electrum-shared.rules @@ -54,7 +54,7 @@ if %direction ^IN$ if %direction ^OUT$ account2 expenses:electrum:%subaccount:BTC - comment2 %timestamp,SPEND,electrum,BTC,%value_without_fee,USD,,From %subaccount + comment2 %timestamp,SPEND,electrum,BTC,%value_without_fee,USD,%fiat_value,From %subaccount if %direction ^OUT$ & %label (Self|Equity transfer|Capital contribution) From bab3021ec7c34177ca906005320ad24ca76cabe9 Mon Sep 17 00:00:00 2001 From: Aaron Fiore Date: Wed, 27 Mar 2024 00:22:26 -0700 Subject: [PATCH 4/4] hledger-flow: electrum: add GIFTIN fiat_value cost-basis note --- .../src/hledger-flow/accounts/electrum/electrum-shared.rules | 1 + 1 file changed, 1 insertion(+) diff --git a/container/src/hledger-flow/accounts/electrum/electrum-shared.rules b/container/src/hledger-flow/accounts/electrum/electrum-shared.rules index 1ec4b93..07d4057 100644 --- a/container/src/hledger-flow/accounts/electrum/electrum-shared.rules +++ b/container/src/hledger-flow/accounts/electrum/electrum-shared.rules @@ -49,6 +49,7 @@ if %direction ^IN$ & %label Gift account2 income:electrum:%subaccount:gifts:BTC comment2 %timestamp,GIFTIN,electrum,BTC,%value_without_fee,USD,%fiat_value,To %subaccount +# NOTE: fiat_value must be manually updated in custom rules if your given cost-basis will be different # OUT