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

Remove .idea/ from version control #611

Open
okarmazin opened this issue Sep 17, 2024 · 4 comments
Open

Remove .idea/ from version control #611

okarmazin opened this issue Sep 17, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@okarmazin
Copy link
Contributor

okarmazin commented Sep 17, 2024

.idea/ should not be checked in to version control since it contains local installation state. There may be the rare shareable configuration, but the vast majority of the content is local to the current IDE installation.

Case in point, just opening Kobweb in my IDEA installation modifies some existing configuration files in .idea/

Kobweb's .gitignore rules allow local IDE state leakage.

I propose that all .idea/ directories be removed from VCS entirely.

@okarmazin okarmazin added the bug Something isn't working label Sep 17, 2024
@bitspittle
Copy link
Member

I totally understand where you're coming from but I disagree with the strength of the opinion. I should actually update my CONTRIBUTING doc to be clear about this.

In short: if people are contributing to Kobweb, I strongly prefer they use IntelliJ IDEA to do so. There is a lot of junk in the .idea that is optional (and we can exclude more of it if identified), but not all of it -- we have been adding (and are open to add more) various formatting rules in there.

If we get more and more contributors over time, it's going to be hard enough to review PRs without some standards, and the .idea folder gives us some tools to help at least remove some of the potential noise.

Here is, I believe, official guidance from JetBrains: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839-How-to-manage-projects-under-Version-Control-Systems

@lppedd
Copy link

lppedd commented Sep 26, 2024

The problem with sharing .idea is that configuration files change between IDEA releases.
I do commit a subset of the folder usually, but only if I'm sure the team is mostly synced with IDE versions.

@bitspittle
Copy link
Member

(Sorry for no reply last week -- was dealing with a bunch of real life distractions!)

Just wanted to thank @lppedd for the extra context. I am going to think about it.

I am also wondering if in general I should be encouraging developers to use either the latest stable or EAP version of IntelliJ IDEA. Of course, if someone uses their own IDE and submits a PR, I won't reject it; but by default, especially if a contributing dev doesn't really have any strong opinions about their own workflow, I'd like to feel like I can rely on specifying some syntax rules in the IDE settings with a chance that uesrs will have them applied in their own code for consistency.

@EchoEllet
Copy link
Contributor

In short: if people are contributing to Kobweb, I strongly prefer they use IntelliJ IDEA to do so. There is a lot of junk in the .idea that is optional (and we can exclude more of it if identified), but not all of it -- we have been adding (and are open to add more) various formatting rules in there.

If we get more and more contributors over time, it's going to be hard enough to review PRs without some standards, and the .idea folder gives us some tools to help at least remove some of the potential noise.

How about a lint tool like ktlint or detekt that's not IDE specific and can be used in CI for checks?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants