Page 1 of 1

.gitignore

Posted: Tue Dec 18, 2018 3:04 am
by filbo
My build directory is littered (by my own actions) with things like rocksndiamonds-sdl2 and rocksndiamonds.old.

git status also whines about various graphics files created by the build.

Code: Select all

$ git diff
diff --git a/.gitignore b/.gitignore
index e884cfc..c521d23 100644
--- a/.gitignore
+++ b/.gitignore
@@ -22,7 +22,9 @@ src/conf_g2s.c
 src/conf_g2m.c
 src/conf_var.c
 src/conf_act.c
+graphics/gfx_classic/*.png
+graphics/gfx_classic/RocksCE.ilbm
+graphics/gfx_classic/overlay/VirtualButtons.png
 
 # ignore compiled executable files
-rocksndiamonds
-rocksndiamonds.exe
+rocksndiamonds*

Re: .gitignore

Posted: Sat Jan 05, 2019 10:26 pm
by HerzAusGold
hi here is my .gitignore
<code>
# ignore temporary development files
*.o
*.a
*.dll
*.png
cpl/
runtime/
.depend

# ignore automatically generated files
src/conftime.h
src/conf_gfx.h
src/conf_snd.h
src/conf_mus.h
src/conf_chr.c
src/conf_chr.h
src/conf_cus.c
src/conf_cus.h
src/conf_grp.c
src/conf_grp.h
src/conf_e2g.c
src/conf_esg.c
src/conf_e2s.c
src/conf_fnt.c
src/conf_g2s.ce
src/conf_g2m.c
src/conf_var.c
src/conf_act.c

# ignore compiled executable files
rocksndiamonds
rocksndiamonds.exe
rocksndiamonds*.exe
rndTest.exe

# ignore transparent files
/src/-transparent

</code>

Holger have changed all C-Comments /* xxxx */ to C++Comments //
even in CONF-Files and even after #define and other preprocessor commands.
Bad to merge, with "Meld" merging is more or less possible.

Re: .gitignore

Posted: Mon Jan 07, 2019 7:15 pm
by Holger
My build directory is littered (by my own actions) with things like rocksndiamonds-sdl2 and rocksndiamonds.old.
Mine too! :D

Solution: Put all those files (file patterns) into the file ".git/info/exclude". (On my system, this is a symlink to "../../.gitignore.private", so I have the public and the private Git ignore file nicely next to each others.)
git status also whines about various graphics files created by the build.
Oops, right! I had these patterns in my private Git ignore file -- moved them to the public Git ignore file now!

Re: .gitignore

Posted: Mon Jan 07, 2019 7:19 pm
by Holger
Holger have changed all C-Comments /* xxxx */ to C++Comments //
even in CONF-Files and even after #define and other preprocessor commands.
Bad to merge, with "Meld" merging is more or less possible.
Not sure what this has to do with Git ignore files, but: If you simply use "git merge" instead of that other tool you used, it is in fact very easy to merge! I've just merged your changes to a copy of the latest "master" branch, and solving those few conflicts after the automatic merge took me less than five minutes.

"git merge" is really powerful...

Re: .gitignore

Posted: Tue Jan 08, 2019 1:44 am
by filbo
You already have 'rocksndiamonds' and 'rocksndiamonds.exe' in .gitignore; it really seems sensible to just change that to 'rocksndiamonds*', anticipating (or in fact reacting to news) that files of that pattern are likely to accumulate there & are ignorable...

Ah, given .gitignore rules, I guess the entry ought to be '/rocksndiamonds*' (ignore them only in the root of the repository).