org中插入yasnippet, 格式失效


#1

要在Org中新建一个消费记录

2019-09-05 * "豆腐脑油条鸡蛋"
                       Assets:DebtWechat -12.00 CNY
                       Expenses:Food:Breakfast

yasnippet template

# -*- mode: snippet -*-
# name: food
# key: food
# condition: t               
# --

`(format-time-string "%Y-%m-%d" (current-time))` * ""
           Assets:DebtWechat  CNY
           Expenses:Food:

插入后, 格式变成了

2019-09-05 * ""
Assets:DebtWechat  CNY
Expenses:Food:

怎样保持原来的对齐格式?


#2

加下面这行试试

# expand-env: ((yas/indent-line 'fixed) (yas/wrap-around-region 'nil))


#3

神奇…


#4

使用ledger mode试试,方便记账哈


#5

觉得ledger mode只能写进src中, 不如beancount好用, 上一段你的用例来给咱学习学习?