Marko Apfel - Afghanistan/Belgium/Germany

Management, Architecture, Programming, QA, Coach, GIS, EAI

  Home  |   Contact  |   Syndication    |   Login
  168 Posts | 2 Stories | 133 Comments | 4 Trackbacks

News



Twitter | LinkedIn | Xing

Article Categories

Archives

Post Categories

BizTalk

C#

Enterprise Library

SAP

SQL Server

Technologie

Initial situation

Often for Visual Studio projects the typical content of a .gitignore file contains this line

  • bin or
  • [B|b]in

It is used to avoid that Git tries to track compile outputs as repository relevant data.

Problem

But keep in mind: this will also suppress bin folders of additional stuff like frameworks and toolsets.
For instance

  • Microsoft.SDKs
    contains a folder named Bin with a lot of programs
  • Simian
    contains a folder named bin with the program themselves

If you store such artifacts also in the repository - according to the principle of a “self containing project” – you could lost the content in the bin folder!

Solution

Till yet I don’t have a good idea.

So I verify for each new added toolset or framework whether it has or has not such a bin folder. If it has, then I must add this bin folder manually to the repository so that Git track it.

posted on Friday, October 5, 2012 8:12 AM

Feedback

# re: Be careful when Git suppresses bin Folders 10/5/2012 2:33 PM Stefan Offermann
Just add a leading slash to suppress recurcive ignoring:

/bin/

...should just ignore the bin folder in the root of the repository. See also:

http://stackoverflow.com/questions/2476718/how-to-i-add-something-to-the-gitignore-so-that-the-match-is-not-recursive

# re: Be careful when Git suppresses bin Folders 10/5/2012 3:29 PM Wyatt Barnett
Run into this with HG as well. Our solution is to keep our sources out of the root of the HG project -- ie, in /src/. Then we ignore src/**/bin/*; usually misses dependencies and SDKs.

# re: Be careful when Git suppresses bin Folders 10/8/2012 5:16 AM Posicionar en Buscadores
interesting to note. Thank you very much for the information.

Post A Comment
Title:
Name:
Email:
Comment:
Verification: