Simpler Tauri resource paths (#112)

This commit is contained in:
Gregory Schier
2024-09-25 09:25:51 -07:00
committed by GitHub
parent d2c33f821c
commit 2be45d6101
8 changed files with 18 additions and 16 deletions

View File

@@ -126,7 +126,7 @@ impl PluginManager {
pub async fn list_plugin_dirs<R: Runtime>(&self, app_handle: &AppHandle<R>) -> Vec<String> {
let plugins_dir = app_handle
.path()
.resolve("plugins", BaseDirectory::Resource)
.resolve("vendored/plugins", BaseDirectory::Resource)
.expect("failed to resolve plugin directory resource");
let bundled_plugin_dirs = read_plugins_dir(&plugins_dir)

View File

@@ -22,7 +22,7 @@ pub async fn start_nodejs_plugin_runtime<R: Runtime>(
) -> Result<()> {
let plugin_runtime_main = app
.path()
.resolve("plugin-runtime", BaseDirectory::Resource)?
.resolve("vendored/plugin-runtime", BaseDirectory::Resource)?
.join("index.cjs");
// HACK: Remove UNC prefix for Windows paths to pass to sidecar