@@ -37,8 +37,8 @@ use yaak_grpc::{Code, ServiceDefinition, serialize_message};
3737use yaak_mac_window:: AppHandleMacWindowExt ;
3838use yaak_models:: models:: {
3939 AnyModel , CookieJar , Environment , GrpcConnection , GrpcConnectionState , GrpcEvent ,
40- GrpcEventType , HttpRequest , HttpResponse , HttpResponseEvent , HttpResponseState , Plugin ,
41- PluginSource , Workspace , WorkspaceMeta ,
40+ GrpcEventType , HttpRequest , HttpResponse , HttpResponseEvent , HttpResponseState , Workspace ,
41+ WorkspaceMeta ,
4242} ;
4343use yaak_models:: util:: { BatchUpsertResult , UpdateSource , get_workspace_export_resources} ;
4444use yaak_plugins:: events:: {
@@ -1345,35 +1345,6 @@ async fn cmd_send_http_request<R: Runtime>(
13451345 Ok ( r)
13461346}
13471347
1348- #[ tauri:: command]
1349- async fn cmd_install_plugin < R : Runtime > (
1350- directory : & str ,
1351- url : Option < String > ,
1352- plugin_manager : State < ' _ , PluginManager > ,
1353- app_handle : AppHandle < R > ,
1354- window : WebviewWindow < R > ,
1355- ) -> YaakResult < Plugin > {
1356- let plugin = app_handle. db ( ) . upsert_plugin (
1357- & Plugin {
1358- directory : directory. into ( ) ,
1359- url,
1360- enabled : true ,
1361- source : PluginSource :: Filesystem ,
1362- ..Default :: default ( )
1363- } ,
1364- & UpdateSource :: from_window_label ( window. label ( ) ) ,
1365- ) ?;
1366-
1367- plugin_manager
1368- . add_plugin (
1369- & PluginContext :: new ( Some ( window. label ( ) . to_string ( ) ) , window. workspace_id ( ) ) ,
1370- & plugin,
1371- )
1372- . await ?;
1373-
1374- Ok ( plugin)
1375- }
1376-
13771348#[ tauri:: command]
13781349async fn cmd_reload_plugins < R : Runtime > (
13791350 app_handle : AppHandle < R > ,
@@ -1658,7 +1629,6 @@ pub fn run() {
16581629 cmd_workspace_actions,
16591630 cmd_folder_actions,
16601631 cmd_import_data,
1661- cmd_install_plugin,
16621632 cmd_metadata,
16631633 cmd_new_child_window,
16641634 cmd_new_main_window,
@@ -1727,6 +1697,7 @@ pub fn run() {
17271697 git_ext:: cmd_git_rm_remote,
17281698 //
17291699 // Plugin commands
1700+ plugins_ext:: cmd_plugins_install_from_directory,
17301701 plugins_ext:: cmd_plugins_search,
17311702 plugins_ext:: cmd_plugins_install,
17321703 plugins_ext:: cmd_plugins_uninstall,
0 commit comments