Delete JetBrains File Associations on Windows - intellij-idea

I used to have 4 JetBrains IDEs: IntelliJ, GoLand, PyCharm, and CLion. However I deleted them because they were npt very light weight and I discovered the greatness of Neovim.
However, whenever I open my file explorer and open a folder with some code, I would see the file name (i.e. main.go) and under the File Type section, it would say JetBrains (IDE) File.
For example;
File Name --------------- File Type
main.go --------------- JetBrains GoLand File
Also, when I right-click the file, it still shows the "Open With (a JetBrains IDE)" despite them being deleted.
Those two problems are occurring with all 4 JetBrains IDEs I used to have (PyCharm, CLion, GoLand, IntelliJ)
My end goal:
When right clicking a file, I don't want the option to open it in a JetBrains IDE (because the IDEs are deleted)
.go / .java / .py (etc) files shouldn't say JetBrains (IDE name) under the File Type section

Related

What is 'Store as project file' in 'Run/Debug Configurations' - JetBrains IDE's

JetBrains IDEs like PhpStorm, WebStorm, PyCharm or IntelliJ have Run/Debug Configurations.
When creating or modifying a configuration, you can select a checkbox with a label "Store as project file".
From what I have seen, this will create a XML representation of the configuration and store the XML file inside a directory (defaults to .run).
What exactly is the benefit / intended use of this?

Module is not listed in IntelliJ "Run Configuration"

Setup:
I have imported the Git project into IntelliJ.
I compiled the project using "make compile"
Issue:
I tried to create a "Run Configuration". The Module is not listed in the drop-down window.
Debugging:
I compared it with a working setup wherein a project was created using "File->New Project" and wherein .iml was automatically created. I see that the problematic project does not have a .iml file. I could not make out any other differences.
Is the absence of .iml file the root-cause for the issue? If so, how to generate this .iml file? Rather than manual writing, I prefer to generate it using GUI to avoid any manual errors. Please suggest.
In Eclipse IDE, one can convert a project from one type to another. Ex: normal project to Maven project. A default project to Java project by editing .project file.

IntelliJ shows decompiled .class file instead of source code

I am having issues with IntelliJ - it shows me a "decompiled" version of the class instead of its source code if I ctrl+click the class.
This is what I see:
I am trying to open regular JDK source files.
The most relevant issue I found is explained here: Java sources replaced by decompiled files in Intellij
The most detailed answer I've found so far is there as well.
Yet it doesn't work for me:
Bytecode Viewer plugin is off.
Java Bytecode Decompiler plugin is off.
Platform, Project and Module all have same JDK version setup.
I have two JDKs available in IntelliJ: jdk1.8.0_161 and jbsdk8u112b287.2_windows_x86 (bundled with IntelliJ, but comes without src.zip). Tried with both (had to specify src.zip of jdk1.8.0_161 for jbsdk8u112b287.2_windows_x86) - no luck
src.zip is not corrupt - I can open it via WinRAR
When added jdk1.8.0_161 to IntelliJ, it automatically found src.zip. When manually adding src.zip to jbsdk8u112b287.2_windows_x86 Sourcepath tab - it started "Scanning for roots", but warned me that it "cannot determine what kind of files the chosen items contain" and offered me to "attach them as 'Sources'" so I agreed.
Tried File > Invalidate Caches / Restart... - same result.
Same issue in 2017.3 and fresh 2018.1 versions of IntelliJ.
Providing path for Documentation makes IntelliJ look for the documentation in the path specified. So it works as it should for both of JDKs. But not for sources.
Everything else works/compiles properly.
My settings:
1. Get the source files
Make sure you have downloaded and installed the source files of the JDK.
I'm on Arch Linux and installed them with pacman -S openjdk8-src which put a src.zip into /usr/lib/jvm/java-8-openjdk/. We'll use that zip file in the next step.
To list source packages of different JDK versions, do pacman -Ss "openjdk.*-src".
See this question on how to get the source files for your specific platform.
2. Point IntelliJ to the source files
In your module settings (open them with F4) under "Platform Settings" → "SDKs" → "Sourcepath", add the zip file containing the JDK source to your project JDK (be sure to pick the right JDK if IntelliJ lists more than one JDK) using the button with the plus sign:
3. Jump into the source
Select a JDK class, like Comparator, using IntelliJ's Search Everywhere or Ctrl+b with the cursor on the name of the class.
I also have the same problem. The problem for my case is that Project SDK is set to 13 [Invalid]. After I can Project SDK to a valid SDK. My problem is solved.
I tried all the things mentioned at other places for this but at the end I was doing a silly mistake. Intellij was pointing to JDK 11 for which there was no source code (I had both the SDKs 8 & 11). I removed JDK 11 and pointed to JDK 8. JDK had the source code, thus now I can see the source code on ctrl click. Also, I had disabled the bytecode viewer and decompiler plugins. Hope this helps some one.
This also happens for large files - IDEA decides to decompile them instead if indexing sources, which can take ages.
If you're willing to accept the drawdown, adding the following in Help | Edit Custom Properties might fix the problem:
idea.max.intellisense.filesize=4096
On ubuntu there was java version “OpenJDK” when I changed to “Oracle Java”, the error went away and javadoc returned
I meet same problem and finally it gone after I copy JDK to another folder and change config in IntelliJ. I think maybe cause there is a space in path before, because it is installed under "Program Files" folder.
For downloading the source code of class files belong to jar you can use download source option present on top right corner in the de-compiled class file.
On my Windows 10, expand maven:
For me going to File -> Project Structure -> Project -> SDK -> Add SDK -> Download JDK and selecting Oracle OpenJDK solved the problem. Prior to that I had a different JDK selected and apparently it didn't include source code
If you are in a maven project make sure in the project structure all the complied folders are in the excluded section.
I suggest to use Linux Instead of windows. It's easy to find and download Java.
If you are using Linux, you can download SDKMAN
Install Java by SDKMAN
# find version
$ sdk list java
# download
$ sdk install java x.y.z-amzn
ctrl+alt+shift+s add JDK
Switch project JDK
If you are using maven , Right click on Project explorer -> choose Maven -> chick on "reload projects"
This did the trick for me:
Make sure you select the option "Project Files" (instead e.g. "Project").

intellij idea doesn't show file status colors

I have an intellij idea Java project under GIT. When I modify a file I don't see any status change in my package view.
I expect to see an indication in the package view that a file was modified.
I Eclipse IDE I can see:

Reading Project Metadata from JetBrains IntelliJ ".idea" Directory

I am looking for information/documentation about reading project information from the .idea directory within projects created with various JetBrains programmes.
In NetBeans it's fairly straightforward: you open nbproject/project.xml and can get the name of the project, as well as the project type (e.g. org.netbeans.modules.php.project).
With .idea, I am having a harder time finding the definitive locations of the data.
Specifically, I am looking for:
Name of the project (if different from root directory name)
Exact software the project was created with (WebStorm vs. PhpStorm vs. PyCharm vs. RubyMine vs. [...])
Name of the project (if different from root directory name)
Look in .idea/.name file (if exists) -- it's a plain text file with single line of text.
Exact software the project was created with (WebStorm vs. PhpStorm vs. PyCharm vs. RubyMine vs. [...])
There is no such info inside AFAIK -- all products use the same folder/format (well, IntelliJ can also use .ipr files IIRC -- legacy format).
Different IDEs may use different types of modules: e.g. PhpStorm/WebStorm only uses WEB_MODULE -- look in .iml file.