使用 Xcode 构建的 Safari 扩展,重建后从 Safari 中消失

xb1*_*itz 4 safari macos xcode safari-extension

我正在尝试使用 Xcode 构建 Safari 扩展,使用本手册:https : //developer.apple.com/documentation/safariservices/safari_app_extensions/building_a_safari_app_extension

它第一次构建良好并实际工作,但是如果我想在更改后重建它,扩展名就会从 Safari 中消失。

这是我正在使用的几个参数:

  • Xcode 应用程序基于 Cacoa App 模板构建
  • 应用程序包含一个 Safari 扩展目标
  • Safari Allowed Unsigned Extension 被选中

控制台抛出以下错误:

  • plug-in <private> pre-screen sees activating state
  • Hub connection error Error Domain=NSCocoaErrorDomain Code=4097 "connection to service named ext.demo.Extension" UserInfo={NSDebugDescription=connection to service named ext.demo.Extension}
  • PlugInKit error in beginUsing: with plugin identifier: <private>, killing plugin

我想我在这里遗漏了一些重要的东西......

Adr*_*mew 5

Clean Build FolderProduct菜单下做一个- 或者 -Shift-Command-K在你再次运行它之前,你应该很高兴!