$ hledger add Adding transactions to journal file .hledger.test Any command line arguments will be used as defaults. Use tab key to complete, readline keys to edit, enter to accept defaults. An optional (CODE) may follow transaction dates. An optional ; COMMENT may follow descriptions or amounts. If you make a mistake, enter < at any prompt to restart the transaction. To end a transaction, enter . when prompted. To quit, enter . at a date prompt or press control-d or control-c. Date [2022/06/06]: Description: breakfast Account 1: expenses:food Amount 1: 15 Account 2: liabilities:credicard:CMB Amount 2 [-15]: Account 3 (or . or enter to finish this transaction): 2022/06/06 breakfast expenses:food 15 liabilities:credicard:CMB
Save this transaction to the journal ? [y]: Saved. Starting the next transaction (. or ctrl-D/ctrl-C to quit) Date [2022/06/06]: Description: Account 1: < Restarting this transaction. Date [2022/06/06]: Description: clothing Using this similar transaction for defaults: 2022/02/05 * opening balances assets:current:cash:bank:CMB 0 assets:current:cash:bank:CCB 0 assets:current:cash:bank:ICBC 100 assets:current:investment:fund:天天基金 100 assets:current:investment:fund:alipay:yu'ebao 100 assets:current:investment:stock:华泰证券 100 assets:current:debit 0 assets:fixed:housing 100 expenses 0 liabilities:credicard:CMB -100 liabilities:credicard:CCB -100 equity:opening/closing balances Account 1 [assets:current:cash:bank:CMB]: expenses:clothing Amount 1 [0]: 600 Account 2 [assets:current:cash:bank:CCB]: liabilities liabilities liabilities:credicard liabilities:credicard:CCB liabilities:credicard:CMB Account 2 [assets:current:cash:bank:CCB]: liabilities:credicard:CMB Amount 2 [-600]: Account 3 (or . to finish this transaction) [assets:current:cash:bank:ICBC]: