mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-27 18:56:09 +01:00
🎨 Supports setting Pandoc parameters for export docx https://github.com/siyuan-note/siyuan/issues/16845
Signed-off-by: Daniel <845765@qq.com>
This commit is contained in:
parent
f6dd1a7d7e
commit
f7d43c48b3
1 changed files with 3 additions and 0 deletions
|
|
@ -325,6 +325,9 @@ func InitConf() {
|
|||
if "" != docxTemplate {
|
||||
params := util.RemoveInvalid(Conf.Export.PandocParams)
|
||||
if gulu.File.IsExist(docxTemplate) && !strings.Contains(params, "--reference-doc") {
|
||||
if !strings.HasPrefix(docxTemplate, "\"") {
|
||||
docxTemplate = "\"" + docxTemplate + "\""
|
||||
}
|
||||
params += " --reference-doc " + docxTemplate
|
||||
Conf.Export.PandocParams = strings.TrimSpace(params)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue