Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integration with Jetbrains IDEs #49

Closed
11 tasks done
nmolham-godaddy opened this issue Apr 13, 2021 · 86 comments
Closed
11 tasks done

Integration with Jetbrains IDEs #49

nmolham-godaddy opened this issue Apr 13, 2021 · 86 comments
Labels
type:integration-request Request for an intergration with an existing tool

Comments

@nmolham-godaddy
Copy link

nmolham-godaddy commented Apr 13, 2021

Enable Fig autocomplete in JetBrains IDEs' integrated terminal

JetBrains IDEs

  • PhpStorm
  • WebStorm
  • CLion
  • pyCharm
  • PyCharm CE
  • IntelliJ IDEA
  • RubyMine
  • GoLand
  • AppCode
  • Rider IDE
  • Android Studio

Are we missing one that you use? Comment below!


Original Issue
Is your feature request related to a problem? Please describe.
It's just going to make it a really solid solution to make fig integrates with PhpStorm internal terminal window

Describe the solution you'd like
PhpStorm is currently the top pick for PHP developers which offers many features (AIO) which for the most part allows you to do all within the IDE without the need to use external programs (ex: Git, Terminal, etc)

So if Fig is able work well with the IDE's internal terminal window. it will make a big difference.

Describe alternatives you've considered
The current alternative is to keep 2 windows open, one for the IDE and other for the terminal (iTerm2)

Additional context
I am not sure if this is the place for it, but the support for the IDE + composer + npm is a killer combo

Thanks for the amazing work

@mschrage mschrage added the type:integration-request Request for an intergration with an existing tool label Apr 13, 2021
@mschrage
Copy link
Member

Thanks for creating the issue! We definitely want to add support for for Jetbrains IDEs.

Whether this is possible comes down to how much they expose with their extension API + to the macOS accessibility API.

In order to build out the integration, we need to...

  1. Locate bounding rect of cursor
  2. Determine when user is typing into a terminal versus the editor
  3. If the IDE allows multiple terminal windows/tabs to be created, determine when the user changes keyboard focus between them

Let me know if you have any thoughts :)

@adam-code-labx
Copy link

Hey @mattschrage I am not a java developer, worked with almost every other language except java.
However this could be an interesting plugin for us to understand how to interact with the built in terminal? https://github.com/anthraxx/intellij-awesome-console (At least it doesn't look as complicated as objective-c 😆)

@mschrage mschrage changed the title PhpStorm terminal integration Integration with Jetbrains IDEs Jun 8, 2021
@mschrage mschrage pinned this issue Jun 8, 2021
@mschrage
Copy link
Member

mschrage commented Jun 8, 2021

Thanks for the suggestion @adam-code-labx! I've looked into the extensions API and it's not clear that it provides the information we need. I plan on investigating further soon!

@geenva
Copy link

geenva commented Jul 8, 2021

IntelliJ IDEA, please!

@PsyGik
Copy link

PsyGik commented Aug 17, 2021

I wanna say Android Studio as well. But since Android Studio is loosely based on JetBrains' IntelliJ IDEA software, I suppose starting with JetBrains' products first makes sense to me. Would love to discuss more!

@olivernybroe
Copy link

Hi, I have done multiple plugins for IntelliJ, and just so everyone are aware, by them creating a plugin it will work for all IntelliJ products, including Android Studio.

@mschrage What specifically is it you guys are looking for in the API? Like what do you need to build an integration?

@mschrage
Copy link
Member

To work with any Jetbrains IDE, we need to somehow get notifications when:

  1. The embedded terminal is opened / closed
  2. A new terminal tab is opened
  3. A user switches terminal tabs / some unique identifier for knowing which terminal tab is currently open
  4. The embedded terminal becomes focused
  5. The embedded terminal loses focus

@olivernybroe did some research into this:

Yeah the IntelliJ API is massive and can be pretty overwhelming. So the terminal which you guys wanna build into is actually a plugin on IntelliJ. https://github.com/JetBrains/intellij-community/tree/master/plugins/terminal

So the terminal plugin registers 3 first-party extension points.

By looking into the class, what it seems like you would need is to get the TerminalView from the project services, run TerminalView#getWidgets and on each of them you can add a listener of the type JBTerminalWidgetListener
https://github.com/JetBrains/intellij-community/blob/master/plugins/terminal/src/org/jetbrains/plugins/terminal/TerminalView.java
https://github.com/JetBrains/intellij-community/blob/master/platform/execution-impl/src/com/intellij/terminal/JBTerminalWidgetListener.java

If you take a look at the JBTerminalWidgetListener it has a lot of the information you need.

@sametcelikbicak
Copy link

Thanks for this issue, also it would be great to support JetBrains Rider IDE terminal

@panckreous
Copy link

RubyMine and AppCode as well would be divine

@sztelzer
Copy link

sztelzer commented Sep 4, 2021

Please add JetBrains GoLand to this list.
There is always multiple terminals open near a Go project.

@kylegrieder
Copy link

Yes, I'll second GoLand as well. I use this daily, as well as WebStorm.

@mschrage
Copy link
Member

Just updated the list to include GoLand, AppCode, RubyMine and RiderIDE!

We've made some good progress on Terminal integrations in the last sprint and I'm pretty optimistic that we'll be able to get Fig working in JetBrains IDEs soon!

@sametcelikbicak
Copy link

Just updated the list to include GoLand, AppCode, RubyMine and RiderIDE!

We've made some good progress on Terminal integrations in the last sprint and I'm pretty optimistic that we'll be able to get Fig working in JetBrains IDEs soon!

That's great news, I'm so excited with new release which is support JetBrains IDEs.

@akashshyamdev
Copy link

That's great 👍

@marggx
Copy link

marggx commented Oct 16, 2021

Any news on this ?

@mschrage
Copy link
Member

@marggx this is one of our goals for the month!

@SeongwoonHong
Copy link

Looking forward to have this 😁

@nmolham-godaddy
Copy link
Author

@mschrage thanks for the hard work, looking forward PhpStorm support

@ronanwp
Copy link

ronanwp commented Nov 24, 2021

It would be great to have this in GoLand as well. Thank you!

@bvitaliyg
Copy link

I think we may need to consider treating Android Studio requests as a part of this ticket as it uses the same engine.

@mschrage
Copy link
Member

mschrage commented Dec 2, 2021

Sorry for the delay on this. We launched decided to focus on stability after the public launch.

The core technical difficulties of integrating with JetBrains IDEs have been figured out -- it is definitely possible! -- but we still need to write the actual integration.

@sametcelikbicak
Copy link

Sorry for the delay on this. We launched decided to focus on stability after the public launch.

The core technical difficulties of integrating with JetBrains IDEs have been figured out -- it is definitely possible! -- but we still need to write the actual integration.

Great news, JetBrains IDE support coming soon, I can't wait 👍

@mschrage
Copy link
Member

mschrage commented Dec 8, 2021

Plugins can be automatically installed by moving them to the plugins folder of IDE. See: https://intellij-support.jetbrains.com/hc/en-us/articles/206544519

@kylegrieder
Copy link

Seeing this comment last night got me hopeful that this is almost ready... 👀

@mschrage
Copy link
Member

JediTerm runs a shells with custom rc files before sourcing the user's. See https://github.com/JetBrains/intellij-community/tree/master/plugins/terminal/resources

@mschrage
Copy link
Member

mschrage commented Dec 22, 2021

If you are interested in getting Fig to work in your favorite JetBrains IDE, would you please run osascript -e 'id of app "NAME OF IDE" and share the output here?

There is a special Christmas present in the works! 🎄🎁

@R-Bower
Copy link

R-Bower commented Mar 11, 2022

Looks like it was an issue with my 2021.3.2 installation. All good now, thanks!

@etcook
Copy link

etcook commented Mar 11, 2022

Forgive me if I'm just being dense, but is there currently a way to get it to "see" the installation if it's not showing up? I added my version + installation method above.

com.jetbrains.intellij
toolbox
2021.3.2 (213.6777.52)

@R-Bower
Copy link

R-Bower commented Mar 11, 2022

Forgive me if I'm just being dense, but is there currently a way to get it to "see" the installation if it's not showing up? I added my version + installation method above.

com.jetbrains.intellij
toolbox
2021.3.2 (213.6777.52)

As mentioned in earlier posts, toolbox installations are spotty. If you still want to use toolbox, you can try the following:

  • Remove jetbrains-extension-2.0.0 from your plugins folder if it exists (default location for toolbox installs is ~/Library/Application Support/JetBrains/WebStorm2021.3/plugins/jetbrains-extension-2.0.0)
  • uninstall WebStorm from jetbrains toolbox.
  • Install WebStorm manually.
  • Follow all of the steps explained here Integration with Jetbrains IDEs #49 (comment)
  • Once you've verified that Fig is working, uninstall the manual WebStorm installation and reinstall via toolbox.

This is how I managed to get the plugin working on the latest (2021.3.2) version from toolbox.

@RodrigoTomeES
Copy link

RodrigoTomeES commented Mar 11, 2022

Hi,

Since I install Fig plugin for Jetbrain I receive this error each time I open a terminal, anyone has a fix for it?

imagen

Also, Fig app say that I need to install the plugin but I already have it.

imagen

imagen

imagen

Thanks!

@kylegrieder
Copy link

can confirm this is now working for me!

toolbox installations of goland, webstorm and phpstorm

@bvitaliyg
Copy link

Has anyone managed to enable the integration in Android Studio?

@kylegrieder
Copy link

@RodrigoTomeES you need to do steps 3 and 4 in this comment: #49 (comment)

@etcook
Copy link

etcook commented Mar 15, 2022

As mentioned in earlier posts, toolbox installations are spotty. If you still want to use toolbox, you can try the following:

I've tried these steps multiple times, but IntelliJ never shows up as an option. Based on the responses here, it looks like Webstorm, PHPStorm, etc are supported, but IDEA might not be.

@RodrigoTomeES
Copy link

@kylegrieder yes, I solved it redoing the steps 3 and 4, it worked well until I receive an update of Fig, maybe the step 3 and 4 should be done with every update.

@Im-Fran
Copy link

Im-Fran commented Mar 16, 2022

If the IDE you use isn't showing up, please determine the bundle identifier of the application and share it here!

Also let me know if you installed it using JetBrains toolbox or directly!

@mschrage:

> osascript -e 'id of app "IntelliJ IDEA"'                                                        
com.jetbrains.intellij

I can confirm the plugin works with toolbox setups, what I did was: Uninstall the IDE from toolbox, install manually, setup fig, uninstall the IDE using toolbox and then reinstalling with toolbox. Can confirm this currently works with PhpStorm in toolbox 😃

@mschrage
Copy link
Member

@Im-Fran @etcook + anyone else interested in Intellij - support will be added in ~2 hours when the next build is released.

I was testing in the community addition and forgot to add the bundle identifier for the paid version. 😅

I think I can add support for Rider/CLion immediately if anyone can share their bundle id. Android Studio will require additional work to support, but should be coming soon as well.

@etcook
Copy link

etcook commented Mar 17, 2022

I think I can add support for Rider/CLion immediately if anyone can share their bundle id. Android Studio will require additional work to support, but should be coming soon as well.

I installed both to get the identifiers for you.

com.jetbrains.rider
com.jetbrains.CLion

anyone else interested in Intellij - support will be added in ~2 hours when the next build is released.

Wonderful!

@mschrage
Copy link
Member

Thanks @etcook - I've just added Rider + CLion. They might have missed the cutoff for the release today but should be included shortly.

@duongleh
Copy link

Hi, I got the same issue with #49 (comment). Running step 3 does not open the System Preferences window. Note that I did make it work before, but since updating to the v1.0.56 (B405) I have to redo all the steps and stuck at step 3 still then.

@Billson7
Copy link

Not sure if i've missed a step, IDEA is not showing for me yet
Screenshot 2022-03-17 at 09 07 13

@Im-Fran
Copy link

Im-Fran commented Mar 18, 2022

Thanks Matt! I can confirm it now works with IntelliJ!

@Im-Fran
Copy link

Im-Fran commented Mar 18, 2022

Not sure if i've missed a step, IDEA is not showing for me yet
Screenshot 2022-03-17 at 09 07 13

I don't know if you're still not seeing IntelliJ, but maybe you could run fig update and fig doctor, before I opened the terminal to test in IntelliJ, fig was auto updated and then I could use Fig :p

@Billson7
Copy link

Billson7 commented Mar 18, 2022

Not sure if i've missed a step, IDEA is not showing for me yet
Screenshot 2022-03-17 at 09 07 13

I don't know if you're still not seeing IntelliJ, but maybe you could run fig update and fig doctor, before I opened the terminal to test in IntelliJ, fig was auto updated and then I could use Fig :p

My intellij was definitely not really out of date 👀

It's working now, thanks! 🎉

@duongleh
Copy link

Hi, I got the same issue with #49 (comment). Running step 3 does not open the System Preferences window. Note that I did make it work before, but since updating to the v1.0.56 (B405) I have to redo all the steps and stuck at step 3 still then.

Update to the latest version and this issue no longer appears 🎉

@mschrage
Copy link
Member

mschrage commented Mar 26, 2022

Support for PyCharm CE and Android Studio is coming in the next release!

  • fixes for some issues that have popped up with conflicts between Fig and JetBrain's shell integrations.

#1083 #1038 #1099 #1069

@JasonTheAdams
Copy link

JasonTheAdams commented Apr 12, 2022

I just got this working on PhpStorm and...

so beautiful

@mschrage
Copy link
Member

In the latest version of Fig, support for JetBrain IDEs is turned on by default! 🎉

Just run fig install --input-method

@F3n67u
Copy link

F3n67u commented Apr 18, 2022

In the latest version of Fig, support for JetBrain IDEs is turned on by default! 🎉

Just run fig install --input-method

@mschrage great work!

@sametcelikbicak
Copy link

In the latest version of Fig, support for JetBrain IDEs is turned on by default! 🎉

Just run fig install --input-method

@mschrage thanks for effort and great work 👍

@mschrage
Copy link
Member

And we just announced this onTwitter!

If you’re enjoying Fig + JetBrains, please share it with your friends :)

@clo4 clo4 unpinned this issue May 13, 2022
@YannCebron
Copy link

@mschrage Thanks a lot for covering our IDEs 👍 It seems the Fig IntelliJ plugin is installed into the application path itself instead of the "additional plugins" path, could you please check and change it? See https://intellij-support.jetbrains.com/hc/en-us/articles/206544519-Directories-used-by-the-IDE-to-store-settings-caches-plugins-and-logs. Otherwise, it is currently detected as "bundled" plugin which is misleading. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:integration-request Request for an intergration with an existing tool
Projects
None yet
Development

No branches or pull requests