How to keep the Attachments path when uploading to the Github Repository? #311
-
Hi, I create new attachments folder for each of my note. For example, Note1's attachments will be put in "Attachments/Note1" and Note2's attachments will be put in "Attachments/Note2". But after uploading my notes to the Github Repository by Obsidian Publisher, all of the attachments will be put in "Attachments". But I want to put the attachments of each note into separate folders. |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 10 replies
-
Nope, but you can use the frontmatter to set a custom folder for each note. |
Beta Was this translation helpful? Give feedback.
-
Hi Lisandra, I've tried both these two ways but it doesn't work.
But I received this error when uploading "Category1/index.md" to the repo with these both two ways: I've enabled "Attachments & embeds -> Structure" {
"github": {
"branch": "main",
"automaticallyMergePR": true,
"dryRun": {
"enable": false,
"folderName": "github-publisher"
},
"tokenPath": "%configDir%/plugins/%pluginID%/env",
"api": {
"tiersForApi": "Github Free/Pro/Team (default)",
"hostname": ""
},
"workflow": {
"commitMessage": "[PUBLISHER] Merge",
"name": ""
},
"verifiedRepo": true
},
"upload": {
"behavior": "obsidian",
"defaultName": "docs",
"rootFolder": "",
"yamlFolderKey": "",
"frontmatterTitle": {
"enable": false,
"key": "title"
},
"replaceTitle": [],
"replacePath": [
{
"regex": "MyBlog",
"replacement": "",
"type": "path"
}
],
"autoclean": {
"enable": true,
"excluded": [
"docs/assets",
"docs/Attachments",
"index.md",
"about.md",
"tags.md"
]
},
"folderNote": {
"enable": false,
"rename": "index.md",
"addTitle": {
"enable": false,
"key": "title"
}
},
"metadataExtractorPath": ""
},
"conversion": {
"hardbreak": false,
"dataview": true,
"censorText": [],
"tags": {
"inline": false,
"exclude": [],
"fields": []
},
"links": {
"internal": false,
"unshared": false,
"wiki": false,
"slugify": false
}
},
"embed": {
"attachments": true,
"overrideAttachments": [],
"keySendFile": [],
"notes": false,
"folder": "docs/Attachments",
"convertEmbedToLinks": "keep",
"charConvert": "->",
"useObsidianFolder": true
},
"plugin": {
"shareKey": "share",
"excludedFolder": [],
"copyLink": {
"enable": false,
"links": "",
"removePart": [],
"transform": {
"toUri": true,
"slugify": "lower",
"applyRegex": []
}
},
"setFrontmatterKey": "Set"
}
} |
Beta Was this translation helpful? Give feedback.
-
Could you please open the console log with the developer panel? |
Beta Was this translation helpful? Give feedback.
-
Hi, there are a lot of errors: |
Beta Was this translation helpful? Give feedback.
-
Okay, here it is:
|
Beta Was this translation helpful? Give feedback.
Note: It's not possible to allow that, because it's not possible to know which file is connected to which note. Plus it cause duplicate image.
Moreover, if you use this type of things in Obsidian, you can use the Obsidian structure in Embeds → Structure (click on enable)