Skip to content

Commit

Permalink
Fix symlinked plugins not working on desktop
Browse files Browse the repository at this point in the history
  • Loading branch information
pjeby committed Oct 16, 2024
1 parent df1d6b4 commit 6e49540
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions main.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ module.exports = class HotReload extends Plugin {
});
}

watch(path) {
async watch(path) {
if (this.app.vault.adapter.watchers.hasOwnProperty(path)) return;
if (this.app.vault.adapter.stat(path).type !== "folder") return;
if ((await this.app.vault.adapter.stat(path)).type !== "folder") return;
if (watchNeeded || this.isSymlink(path)) this.app.vault.adapter.startWatchPath(path, false);
}

Expand Down
4 changes: 2 additions & 2 deletions manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
"name": "Hot Reload",
"author": "PJ Eby",
"authorUrl": "https://github.com/pjeby",
"version": "0.1.12",
"minAppVersion": "0.15.9",
"version": "0.1.13",
"minAppVersion": "1.5.8",
"isDesktopOnly": true,
"description": "Automatically reload in-development plugins when their files are changed"
}
4 changes: 4 additions & 0 deletions versions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"0.1.13": "1.5.8",
"0.1.11": "0.15.9"
}

0 comments on commit 6e49540

Please sign in to comment.