CopilotForXcode

The missing GitHub Copilot, Codeium and ChatGPT Xcode Source Editor Extension

OTHER License

Stars
7.2K
Committers
10

Bot releases are visible (Hide)

CopilotForXcode - 0.8.5

Published by intitni over 1 year ago

  • May fix #43 that the app is freezing for some users by changing LazyVGrid to VStack (Why?). Big thanks to @timwredwards and @cr2s367067 for helping me locate the bug. I wasn't able to reproduce the bug on 2 of my machines, so I'm not completely certain that it's fixed or that it won't resurface in the future.
  • Done some cleanup in the suspicious areas that look relevant to the bug.
  • Updated copilot.vim to 1.8.3

If the app still freezes, please reply to issue #43, and give 0.8.4 a try. Maybe I made some mistakes again, sigh.

CopilotForXcode - 0.8.4-pre-release

Published by intitni over 1 year ago

Update 1: Remove an unused preference key

This is a quick fix to #43. I am not sure if it's the real fix, so it will stay as a pre-release for a while.

If you have encountered this issue and find that the update fixes it, please give this release an emoji. If it's still not working, please reply to issue #43

Big thanks to @timwredwards and @cr2s367067 for helping me locate the bug.

Good night everyone.

CopilotForXcode - 0.8.3

Published by intitni over 1 year ago

If the app is freezing for you, please check the 0.8.4 pre-release

  1. Add a new toggle to enable the floating widget to align with the text cursor for a more obvious suggestion display.
  2. Remove the requirement for Input Monitoring. Accessibility API permissions can already achieve input monitoring. The Input Monitoring was used because I wanted to use listenOnly instead of defaultTap. But the term was scary to some users.
  3. Bring back real-time suggestion when the completion panel is shown.
  4. Support syntax highlighting, and display spaces as middle dots. Fix line break mode of suggestion (by accident).
  5. Hide the real-time suggestion indicator for floating widget mode.
  6. Fix that if you switch to another file during the fetch of a suggestion, the suggestion from the previous file will still be presented.
  7. Lower the widget's z level, which is currently set too high.
  8. Fix that real-time suggestion cancellation fails after switching to another app and back to Xcode.
  9. Update to use release rss to check for update

The next update will focus on some ChatGPT-powered features because my free credits are expiring soon! We will start with some simple commands like "Explain Selected Code".

CopilotForXcode - 0.8.2

Published by intitni over 1 year ago

  • Fix that the app may just freeze.

To quickly fix the bug, I need to disable the feature to generate real-time suggestions when the Xcode completion panel is displayed. I will bring a better fix soon. For now, if Input Monitoring is turned on, you can hit ESC to close the panel and at the same time trigger real-time suggestion.

  • Add automatically check for update, you can turn in on in the host app.

The 0.8 update:

  • I have added a new presentation mode called 'Floating Widget', which can be turned on from the host app. In this mode, suggestions will be presented in a floating window next to a floating widget.

    The floating widget will stay at the bottom of the editor area and will automatically move left or right if there is not enough space for the suggestion window.

    If a suggestion is presented, you can click on the widget to hide/show it.

  • Real-time suggestions have been improved with the following tweaks:
    • It can now be triggered without requiring Input Monitoring permissions. However, if you want to enable the cancellation feature using esc or mouse click, Input Monitoring is still necessary.
    • The likelihood of the editor being blocked has been significantly reduced. Blocking will only occur at most once for each file after each restart of the extension. Once a command has been executed and some information is cached, the extension will be able to trigger real-time suggestion using a different method that doesn't cause any blocking.
  • Replace the display link with AXObserver for better performance.
  • Fix that the settings in the host app were not reflecting the real settings.
  • And maybe something else I don't remember.

I personally find the floating widget mode to be quite good, and I'm starting to feel like the real-time suggestion mode is finally usable. If you have any suggestions about the floating widget mode, please reply to this issue.

CopilotForXcode - 0.8.1

Published by intitni over 1 year ago

Known issue: The app may freeze when getting suggestions! Looking into it now!

  • I have added a new presentation mode called 'Floating Widget', which can be turned on from the host app. In this mode, suggestions will be presented in a floating window next to a floating widget.

    The floating widget will stay at the bottom of the editor area and will automatically move left or right if there is not enough space for the suggestion window.

    If a suggestion is presented, you can click on the widget to hide/show it.

  • Real-time suggestions have been improved with the following tweaks:
    • It can now be triggered without requiring Input Monitoring permissions. However, if you want to enable the cancellation feature using esc or mouse click, Input Monitoring is still necessary.
    • The likelihood of the editor being blocked has been significantly reduced. Blocking will only occur at most once for each file after each restart of the extension. Once a command has been executed and some information is cached, the extension will be able to trigger real-time suggestion using a different method that doesn't cause any blocking.
  • Replace the display link with AXObserver for better performance.
  • Fix that the settings in the host app were not reflecting the real settings.
  • And maybe something else I don't remember.

I personally find the floating widget mode to be quite good, and I'm starting to feel like the real-time suggestion mode is finally usable. If you have any suggestions about the floating widget mode, please reply to this issue.

The next thing I want to do is to integrate ChatGPT to this extension.

CopilotForXcode - 0.7.0

Published by intitni over 1 year ago

There are some breaking changes in this release. The very first change is that the XPC service is now an accessory app target located in a different location. So if you are upgrading to this version, please open the app once to let it set up the new launch agent for you. The permissions should now be granted to the accessory app, please see the readme for details.

I need to make these changes because the accessory app is taking on more responsibilities like presenting GUI elements. And the old CLI was placed in a wrong directory and caused a lot of problems.

Here are the other changes:

  • The real-time suggestion toggle is now universal, not workspace specific.
  • Added a menu bar item for the accessory app. The icon looks like a steering wheel.
  • The accessory app now launches on demand. You can set it to also quit automatically in the host app.
  • A breathing dot will appear next to the mouse pointer or text cursor when real-time suggestion is turned on. It will have a different animation when prefetch occurs.
  • Bump copilot.vim to 1.8.2

And some bugfixes:

  • Remove warnings from the language server protocol. It may have sped up the Copilot a little bit. But the real-time suggestion still feels very slow.
  • Fix that real-time suggestion not working when the Xcode autocomplete panel is displayed. (Oh, I mean it's now a feature, not a bug any more.)
  • Fix that running command triggers real-time suggestion.

I would like to implement the feature to present suggestions in windows in the next release (no ETA). But I am not sure where to place the window. Snap it to the display corners? To the window corners? If you have an idea, please feel free to let me know.

CopilotForXcode - 0.6.0

Published by intitni over 1 year ago

  • Ignore empty suggestions and fix wrong suggestion comment positions. #17 fixes #15
  • Tapping escape will now cancel in-flight real-time suggestion fetches. #18
  • Starting with the next update, the XPC service will be able to restart itself on update. But for this update, please restart manually. #19

The app can now be installed via Homebrew:

brew install --cask copilot-for-xcode
CopilotForXcode - 0.5.0

Published by intitni almost 2 years ago

  • Add a "Prefetch Suggestions" command that returns immediately to avoid the editor blocking issue, the debounce threshold is lowered, too. But when the suggestion is ready, and you are not typing, it will call "Real-time Suggestions" to present the suggestions, this command can still block the editor.
  • Real-time suggestions will be triggered only by key-up, similar to VSCode. Key-down, mouse-up, and mouse-down will cancel the in-flight prefetches.
  • The state of real-time suggestions is now persisted, so if you turn it on for a workspace/project, it will still be on after the XPC Service restarts.
  • There will be a warning in the app if the version number of the XPC Service and the app don't match.
  • Updated Copilot.vim to 1.8.0.

Don't forget to restart XPC Service in the app after updates.

CopilotForXcode - 0.4.0

Published by intitni almost 2 years ago

  • Tweaked real-time suggestions.

It's now less likely to block your input unless you are typing slowly. And the block will be much shorter. But yes, it can still block the editor.

It feels more stable now, but I haven't had enough tests on it. If you are willing to try it out and provide feedback, please reply to this discussion

(Make sure you restart the XPC Service after the update.)

(Real-time suggestions will not be automatically enabled after the XPC Service is restarted. You will need to manually turn them on again.)

CopilotForXcode - 0.3.1

Published by intitni almost 2 years ago

  • Support customizing path to Node. (You will need to restart the XPC Service after changes.)
  • Display user code in an alert so that it's more obvious.

Known Issues:

  • If real-time suggestions is triggered, it will block the editor until the result is returned.
  • And it's not that reliable currently.
CopilotForXcode - 0.3.0

Published by intitni almost 2 years ago

New Features:

  • (a naive version of) Real-time suggestions.

    you can turn it on for the currently open project with the new action "Turn On Realtime Suggestions for Workspace".

  • A button in the app to restart XPC service.

Fixes:

  • Wrong relative file path passed to Copilot.

Improvements:

  • When AppleScript failed to find the project root, we now search for a parent directory containing a .git directory.

Known Issues:

  • If real-time suggestions is triggered, it will block the editor until the result is returned.
  • And it's not that reliable currently.
  • It's only searching /usr/bin:/usr/local/bin for node, if your node is installed somewhere else, consider making a symbolic link, or try the Copilot.for.Xcode.app.custom.path.to.node.zip. Trying the new package is preferred, please let me know if the custom path solution is working for you!
CopilotForXcode -

Published by intitni almost 2 years ago

In the previous version, whichever action you trigger will replace the whole content in the file. That will cause the editor to select all content and jump to the top when you undo or redo.

In this update, the content will be mutated in place, so undoing and redoing will be fine now.

If you are updating from the previous version, you may need to remove and re-setup the Launch Agent or you can manually disable then enable it.

CopilotForXcode - 0.1.0

Published by intitni almost 2 years ago

Fighting with Xcode Source Editor Extension for this long, a fear that it may only work on my own Mac was grown.

Please tell me if it's not working for you.