Swift support
I love this plugin. Can you please make it support Swift as well?
+1
good
+1
+1
+1
Any hints or ideas on how to implement the Swift support?
Take a look at IDEIndexCompletionStrategy+KSImageNamed.m and Completions.plist. That's where the checks are performed to match imageNamed methods.
Is there any way how to debug (using lldb console, etc.) a Xcode plugin? Is it even possible as Xcode needs to be restarted to load the plugin?
I have added the following to Completitions.plist:
<dict>
<key>classAndMethod</key>
<string>named:</string>
<key>methodDeclaration</key>
<string>named:</string>
<key>methodName</key>
<string>named</string>
<key>comment</key>
<string>Standard NSImage/UIImage method in Swift</string>
</dict>
However, any of the swizzled methods in IDEIndexCompletionStrategy+KSImageNamed.m are being called when I write something that ends "named:" in a swift file. The method swizzle_shouldAutoCompleteAtLocation detects the suffix correctly and returns YES, though. Any ideas how to debug it?
I debug plugins by starting a second instance of Xcode through lldb from the command line. That way I can keep building from the original version of Xcode and relaunch and attach to a second process.
I don't have any suggestions off the top of my head with what you're running into other than to start setting breakpoints at the main swizzled methods and start tracing your way through everything, sorry. I haven't looked into how code completion works with Swift, but I'd be surprised if it's using a completely separate completion implementation (and thus require a whole lot of additional swizzling).
+1 would love to see a new version with swift support in alcatraz
+1
+1
+1
+1
+1
+1, great plugin
+1
+1
+1