File tree Expand file tree Collapse file tree 2 files changed +11
-4
lines changed
Expand file tree Collapse file tree 2 files changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -75,15 +75,21 @@ public class CopilotBaseService {
7575
7676 return InitializeParams (
7777 processId: Int ( ProcessInfo . processInfo. processIdentifier) ,
78+ clientInfo: . init( name: " Copilot for Xcode " ) ,
7879 locale: nil ,
79- rootPath: nil ,
80+ rootPath: projectRoot . path ,
8081 rootUri: projectRoot. path,
8182 initializationOptions: nil ,
8283 capabilities: capabilities,
8384 trace: nil ,
8485 workspaceFolders: nil
8586 )
8687 }
88+
89+ server. notificationHandler = { _, respond in
90+ respond ( nil )
91+ }
92+
8793 return server
8894 } ( )
8995}
Original file line number Diff line number Diff line change @@ -75,8 +75,9 @@ enum Environment {
7575 )
7676 }
7777 }
78- if let path {
79- return URL ( fileURLWithPath: path)
78+ if let path = path? . removingPercentEncoding {
79+ let url = URL ( fileURLWithPath: path. replacingOccurrences ( of: " file:// " , with: " " ) )
80+ return url
8081 }
8182 } catch {
8283 if let axError = error as? AXError , axError == . apiDisabled {
@@ -109,7 +110,7 @@ enum Environment {
109110
110111 guard let activeXcode = xcodes. first ( where: { $0. isActive } ) else { return }
111112 let bundleName = Bundle . main. object ( forInfoDictionaryKey: " EXTENSION_BUNDLE_NAME " ) as! String
112-
113+
113114 /// check if menu is open, if not, click the menu item.
114115 let appleScript = """
115116 tell application " System Events "
You can’t perform that action at this time.
0 commit comments