[PATCH] Addition of JetBrains project directory to .gitignore

Started by David Nedrowalmost 7 years ago6 messageshackers
Beta feature

Hackorum builds and tests every patch posted to the lists, not only commitfest submissions. This is Hackorum's own CI rather than the PostgreSQL project's, and it is still under testing - please report anything that looks wrong.

appliessuccessCI history

You can run a PostgreSQL built from this patch straight from Docker, with no checkout and no build:

docker run --rm -p 5432:5432 ghcr.io/hackorum-dev/postgres-patch:t41606
psql -h localhost -U postgres

Built from patchset v1 (message #1), September 20, 2026 at 12:27 PM.

Every patchset is also pushed to a branch of our PostgreSQL fork, so you can check out the same tree CI built. Without a PostgreSQL checkout:

git clone --branch t41606_1 https://github.com/hackorum-dev/postgres.git

In a checkout you already have, add the fork once:

git remote add hackorum https://github.com/hackorum-dev/postgres.git

then, for this patchset and every later one:

git fetch hackorum t41606_1 && git checkout t41606_1

Patchset v1 (message #1) is on t41606_1

Jump to latest
#1David Nedrow
dnedrow@me.com

This patch simply adds “.idea/“ to the list of global excludes across all subdirectories. This directory is created when a JetBrains IDE is used to open a project. In my specific case, Clion is creating the project directory.

The ONLY change in the patch is the “.idea/“ addition to .gitignore.

David Nedrow
dnedrow@me.com

Attachments:

t41606_1
gitignore-JetBrains-v1.patchapplication/octet-stream; name=gitignore-JetBrains-v1.patch; x-unix-mode=0644Download+1-0
#2Daniel Gustafsson
daniel@yesql.se
In reply to: David Nedrow (#1)
Re: [PATCH] Addition of JetBrains project directory to .gitignore

On 3 Dec 2019, at 15:47, David Nedrow <dnedrow@me.com> wrote:

This patch simply adds “.idea/“ to the list of global excludes across all subdirectories. This directory is created when a JetBrains IDE is used to open a project. In my specific case, Clion is creating the project directory.

The ONLY change in the patch is the “.idea/“ addition to .gitignore.

-1. This seems like something better suited in a local gitignore for those who
use Jetbrains products. See the documentation for ~/.gitignore_global.

cheers ./daniel

#3Daniel Gustafsson
daniel@yesql.se
In reply to: David Nedrow (#1)
Re: [PATCH] Addition of JetBrains project directory to .gitignore

On 3 Dec 2019, at 15:56, David Nedrow <dnedrow@me.com> wrote:

Hmmm. I can see that. However, there are already entries for Microsoft Visual C++ at the global level. Wouldn’t this fall into the same category?

Not really, the files in the current .gitignore are artifacts of the build-
system which is provided by the postgres tree (MSVC building, gcov etc); there
are no editor specific files ignored there.

cheers ./daniel

#4Tom Lane
tgl@sss.pgh.pa.us
In reply to: Daniel Gustafsson (#2)
Re: [PATCH] Addition of JetBrains project directory to .gitignore

Daniel Gustafsson <daniel@yesql.se> writes:

On 3 Dec 2019, at 15:47, David Nedrow <dnedrow@me.com> wrote:
This patch simply adds “.idea/“ to the list of global excludes across all subdirectories. This directory is created when a JetBrains IDE is used to open a project. In my specific case, Clion is creating the project directory.

The ONLY change in the patch is the “.idea/“ addition to .gitignore.

-1. This seems like something better suited in a local gitignore for those who
use Jetbrains products. See the documentation for ~/.gitignore_global.

Yeah, we already have a policy that we won't add entries for, say,
editor backup files. This seems like the same thing. It's stuff
generated by a tool you use, and you'd need it for any project
you work on, so a personal ~/.gitexclude seems like the answer.

(Roughly speaking, I think the project policy is/should be that only
junk files created by application of build rules in our Makefiles
should be excluded by our own .gitexclude files.)

As a point of reference, I have

$ cat ~/.gitexclude
*~
*.orig

to suppress emacs backup files and patch backup files respectively.
Somebody who prefers another editor would have no use for *~.

regards, tom lane

#5David Nedrow
dnedrow@me.com
In reply to: Tom Lane (#4)
Re: [PATCH] Addition of JetBrains project directory to .gitignore

Got it, and that makes sense.

I hereby withdraw this patch. ;)

- David

Show quoted text

On Dec 3, 2019, at 10:08, Tom Lane <tgl@sss.pgh.pa.us> wrote:

Daniel Gustafsson <daniel@yesql.se> writes:

On 3 Dec 2019, at 15:47, David Nedrow <dnedrow@me.com> wrote:

This patch simply adds “.idea/“ to the list of global excludes across all subdirectories. This directory is created when a JetBrains IDE is used to open a project. In my specific case, Clion is creating the project directory.

The ONLY change in the patch is the “.idea/“ addition to .gitignore.

-1. This seems like something better suited in a local gitignore for those who
use Jetbrains products. See the documentation for ~/.gitignore_global.

Yeah, we already have a policy that we won't add entries for, say,
editor backup files. This seems like the same thing. It's stuff
generated by a tool you use, and you'd need it for any project
you work on, so a personal ~/.gitexclude seems like the answer.

(Roughly speaking, I think the project policy is/should be that only
junk files created by application of build rules in our Makefiles
should be excluded by our own .gitexclude files.)

As a point of reference, I have

$ cat ~/.gitexclude
*~
*.orig

to suppress emacs backup files and patch backup files respectively.
Somebody who prefers another editor would have no use for *~.

regards, tom lane

#6Michael Paquier
michael@paquier.xyz
In reply to: Tom Lane (#4)
Re: [PATCH] Addition of JetBrains project directory to .gitignore

On Tue, Dec 03, 2019 at 10:07:08AM -0500, Tom Lane wrote:

As a point of reference, I have

$ cat ~/.gitexclude
*~
*.orig

to suppress emacs backup files and patch backup files respectively.
Somebody who prefers another editor would have no use for *~.

Here are extra entries I use for example:
# Files created by vim for unsaved changes
.*.swp
# Files created by emacs for unsaved changes
.#*
# Temporary files created during compilation
*.o-*
# Tags generated by etags or ctags
TAGS
tags
# Files created by ./configure
conftest.c
conftest.err
confdefs.h
--
Michael