Standard Notes Extensions 安装
Standard Notes 的 Extensions 需要额外付费,按月单独付费的话,一个月要$9.99。其实除了几个网盘同步的扩展外,其他扩展(包括主题)都是开源的,可以自己host。
第一步,新建一个文件夹,先批量把SN的扩展源代码clone到本地。参考文章Github中如何批量Clone某人/组织的库。假定目录为/var/hosts/sn-extensions
然后Caddy添加一个新域名(原域名单独指定某个文件夹也可以),root指向clone下来的sn-extensions
目录。
https://sn-ext.test.com {
gzip
tls /etc/ssl/caddy/server.crt /etc/ssl/caddy/server.key {
curves p521 p384 X25519 p256
}
mime {
.css text/css
}
root /var/hosts/sn-extensions
}
最麻烦的一步,每个扩展/主题,都需要在文件夹内单独创建
一个ext.json
,里面放置相关的扩展配置信息。比如/var/hosts/sn-extensions/advanced-markdown-editor/ext.json
配置参考如下:
{
"identifier": "com.test.sn-ext.advanced-markdown-editor",
"name": "Advanced Markdown",
"content_type": "SN|Component",
"area": "editor-editor",
"version": "1.2.8",
"url": "https://sn-ext.test.com/advanced-markdown-editor/index.html"
}
{
"identifier": "com.test.sn-ext.code-editor",
"name": "Code Editor",
"content_type": "SN|Component",
"area": "editor-editor",
"version": "1.2.7",
"url": "https://sn-ext.test.com/code-editor/index.html"
}
{
"identifier": "com.test.sn-ext.plus-editor",
"name": "Plus Editor",
"content_type": "SN|Component",
"area": "editor-editor",
"version": "1.2.6",
"url": "https://sn-ext.test.com/plus-editor/index.html"
}
{
"identifier": "com.test.sn-ext.autocomplete-tags",
"name": "Quick Tags",
"content_type": "SN|Component",
"area": "note-tags",
"version": "1.0.0",
"url": "https://sn-ext.test.com/autocomplete-tags/index.html"
}
{
"identifier": "com.test.sn-ext.folders-component",
"name": "Folders",
"content_type": "SN|Component",
"area": "tags-list",
"version": "1.0.0",
"url": "https://sn-ext.test.com/folders-component/index.html"
}
{
"identifier": "com.test.sn-ext.secure-spreadsheets",
"name": "Secure Spreadsheets",
"content_type": "SN|Component",
"area": "editor-editor",
"version": "1.2.6",
"url": "https://sn-ext.test.com/secure-spreadsheets/dist/index.html"
}
{
"identifier": "com.test.sn-ext.simple-task-editor",
"name": "Simple Task Editor",
"content_type": "SN|Component",
"area": "editor-editor",
"version": "1.2.6",
"url": "https://sn-ext.test.com/simple-task-editor/dist/index.html"
}
{
"identifier": "com.test.sn-ext.simple-markdown-editor",
"name": "Simple Markdown",
"content_type": "SN|Component",
"area": "editor-editor",
"version": "1.2.6",
"url": "https://sn-ext.test.com/simple-markdown-editor/dist/index.html"
}
{
"identifier": "com.test.sn-ext.action-bar",
"name": "Action Bar",
"content_type": "SN|Component",
"area": "editor-stack",
"version": "1.0.0",
"url": "https://sn-ext.test.com/action-bar/index.html"
}
{
"identifier": "com.test.sn-ext.focus-theme",
"name": "Focused",
"content_type": "SN|Component",
"area": "themes",
"version": "1.2.3",
"url": "https://sn-ext.test.com/focus-theme/dist/dist.css"
}
{
"identifier": "com.test.sn-ext.midnight-theme",
"name": "Midnight",
"content_type": "SN|Component",
"area": "themes",
"version": "1.0.0",
"url": "https://sn-ext.test.com/midnight-theme/dist/dist.css"
}
{
"identifier": "com.test.sn-ext.dynamic-theme",
"name": "Dynamic",
"content_type": "SN|Component",
"area": "themes",
"version": "1.0.0",
"url": "https://sn-ext.test.com/dynamic-theme/dist/dist.css"
}
{
"identifier": "com.test.sn-ext.futura-theme",
"name": "Futura",
"content_type": "SN|Component",
"area": "themes",
"version": "1.0.0",
"url": "https://sn-ext.test.com/futura-theme/dist/dist.css"
}
{
"identifier": "com.test.sn-ext.solarized-dark-theme",
"name": "Solarized Dark",
"content_type": "SN|Component",
"area": "themes",
"version": "1.0.0",
"url": "https://sn-ext.test.com/solarized-dark-theme/dist/dist.css"
}
最后访问起来的URL类似https://sn-ext.test.com/advanced-markdown-editor/ext.json
,访问后的内容类似下面
{
"identifier": "com.test.sn-ext.advanced-markdown-editor",
"name": "Advanced Markdown",
"content_type": "SN|Component",
"area": "editor-editor",
"version": "1.2.8",
"url": "https://sn-ext.test.com/advanced-markdown-editor/index.html"
}
然后打开Standard Notes客户端,点击Extensions
-Import Extension
,挨个输入ext.json的URL:https://sn-ext.test.com/advanced-markdown-editor/ext.json
、https://sn-ext.test.com/focus-theme/ext.json
,把自己需要的扩展都添加完。
添加完的扩展,会在所有的客户端(Android、iOS、Web等)自动加载,不需要重复添加。