mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-09 08:44:20 +01:00
Signed-off-by: Daniel <845765@qq.com>
This commit is contained in:
parent
18761d43a3
commit
c1a6206f7b
1 changed files with 5 additions and 0 deletions
|
|
@ -3411,6 +3411,11 @@ func exportPandocConvertZip(baseFolderName string, docPaths, defBlockIDs []strin
|
|||
name = util.FilterFileName(name)
|
||||
hPath = path.Join(dir, name)
|
||||
p = hPath + ext
|
||||
if 1 == len(docPaths) {
|
||||
// 如果仅导出单个文档则使用文档标题作为文件名,不使用父路径 https://github.com/siyuan-note/siyuan/issues/13635#issuecomment-3794560233
|
||||
p = name + ext
|
||||
}
|
||||
|
||||
writePath := filepath.Join(exportFolder, p)
|
||||
hash := fmt.Sprintf("%x", sha1.Sum([]byte(md)))
|
||||
if gulu.File.IsExist(writePath) && hash != wrotePathHash[writePath] {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue