{"id":48132255,"url":"https://github.com/vran-dev/obsidian-attachment-pro","last_synced_at":"2026-04-04T16:40:20.377Z","repository":{"id":214953427,"uuid":"737281185","full_name":"vran-dev/obsidian-attachment-pro","owner":"vran-dev","description":null,"archived":false,"fork":false,"pushed_at":"2025-11-18T03:57:12.000Z","size":262,"stargazers_count":24,"open_issues_count":6,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-11-18T05:34:57.951Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vran-dev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-12-30T13:13:13.000Z","updated_at":"2025-11-18T03:57:16.000Z","dependencies_parsed_at":"2024-01-07T15:46:48.349Z","dependency_job_id":"8546f830-3c20-4dd3-9af1-7e9d6439b413","html_url":"https://github.com/vran-dev/obsidian-attachment-pro","commit_stats":null,"previous_names":["vran-dev/obsidian-attachment-pro"],"tags_count":3,"template":false,"template_full_name":"obsidianmd/obsidian-sample-plugin","purl":"pkg:github/vran-dev/obsidian-attachment-pro","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vran-dev%2Fobsidian-attachment-pro","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vran-dev%2Fobsidian-attachment-pro/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vran-dev%2Fobsidian-attachment-pro/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vran-dev%2Fobsidian-attachment-pro/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vran-dev","download_url":"https://codeload.github.com/vran-dev/obsidian-attachment-pro/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vran-dev%2Fobsidian-attachment-pro/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31405708,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-04T10:20:44.708Z","status":"ssl_error","status_checked_at":"2026-04-04T10:20:06.846Z","response_time":60,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-04-04T16:40:19.840Z","updated_at":"2026-04-04T16:40:20.370Z","avatar_url":"https://github.com/vran-dev.png","language":"TypeScript","readme":"## 介绍\n\nattachmentPro 是一款 obsidian 附件管理插件，支持设置多个附件管理规则。\n\n附件的规则优先级是按照设置的顺序来的，比如设置了两个规则，第一个规则的适用范围是 `指定目录`，第二个规则的适用范围是 `全部`，那么第一个规则会优先生效。\n\n![alt text](attachment/image.png)\n\n## 文件存放位置\n\n| 选项 | 说明 |\n| --- | --- |\n| 仓库的根目录 | obsidian 笔记库的所在目录 |\n| 当前文件所在目录 | 即保存到所粘贴的笔记所在的目录下，比如笔记是 `notes/2024-01-01.md`，那么图片会保存在 `notes` 目录下 |\n| 当前文件所在子目录 | 需要指定一个目录路径，比如笔记是 `notes/2024-01-01.md`，如果指定的子目录是 `attachments`，那么附件会保存到 `notes/attachments/` 下 |\n| 自定义 | 可以引用变量（见下文），比如指定规则为 `${yearmonth}/`，插件就会将附件按年月分组保存在不同的目录下 |\n\n## 适用范围\n\n适用范围是指插件会在哪些笔记中、或者针对哪些附件生效，目前支持 4 种类型\n\n| 选项 | 说明 |\n| --- | --- |\n| 指定目录 | 只有笔记在指定的目录路径下才会应用该附件管理规则 |\n| 指定标签 | 笔记中包含指定标签时，才会应用该附件管理规则 |\n| 指定文件类型 | 附件类型，比如 `png`、`pdf` 等 |\n| 全部 | 适用于所有笔记，以及所有附件类型 |\n\n## 文件名格式化\n\n即重命名附件的名称，支持 4 种方式 \n\n| 选项 | 说明 |\n| --- | --- |\n| 原始文件名 | 不做任何处理 |\n| 当前时间 | 以当前时间作为附件名称，可以自定义时间的格式 |\n| UUID | 生成一个唯一的 UUID |\n| 自定义格式 | 可以引用变量（见下文），比如笔记为 `2024-01-01`，重命名规则为 `${notename}-${timestamp}`，插件就会将附件重命名为 `2024-01-01-1708144120727` |\n\n## 变量\n\n| 变量名 | 描述 | 示例 |\n| --- | --- | --- |\n| ${attachmentName} | 附件名称 |  |\n| ${notename} | 笔记名称 |  |\n| ${timestamp} | 时间戳 | 1708144120727 |\n| ${now} | 当前时间，可以通过 ${now.toFormat('yyyyMMddHHmmss')} 来格式化 |  |\n| ${year} | 年 | 2024 |\n| ${yearmonth} | 年月 | 202401 |\n| ${file} | Obsidian 笔记文件对象 | |\n| ${frontmatter} | Obsidian 笔记 frontmatter 对象, 可以引用笔记的属性，比如 ${frontmatter.created} 就表示应用了 created 属性 | |\n\n## 附件库使用方法\n- `ctrl+p`(默认快捷键)打开obsidian命令窗口，\n- 输入`Show Attachments`，选择`Attachment Pro: Show Attachments`命令，打开附件库。\n![alt text](attachment/README-Screenshot_241117_123739.png)\n\n**或者**\n\n- 在左侧 边栏中点击`Show Attachments`图标，打开附件库。\n![alt text](attachment/README-Screenshot_241117_123649.png)","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvran-dev%2Fobsidian-attachment-pro","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvran-dev%2Fobsidian-attachment-pro","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvran-dev%2Fobsidian-attachment-pro/lists"}