Should an empty bin/ directory be checked in? [message #777310] |
Tue, 10 January 2012 09:08 |
Matthew Webber Messages: 198 Registered: December 2010 |
Senior Member |
|
|
Our Java projects (mostly plugins) use a fairly standard layout, with Java source in src/ (and sometimes test/) directories, which get compiled to a bin/ directory. Obviously, the source code, but not the compiled classes, get checked in to the repository.
Previously, we used subversion, and had svn:ignore set so that neither bin/ nor its contents were checked in to the respoitory. Hence there is no bin/ in the repository at all.
We're moving to Git, so I'm reviewing the way we do things. What's best:
(1) Don't have bin/ in the respository (specified by .gitignore in the project parent directory)
OR
(2) Check an empty bin/ in the respository (empty except for a .gitignore in the bin/ directory)
Is one way better than the other, or is it just a case of personal preference? I'm leaning towards (2).
Thanks
Matthew
|
|
|
Re: Should an empty bin/ directory be checked in? [message #777320 is a reply to message #777310] |
Tue, 10 January 2012 09:16 |
Dani Megert Messages: 3802 Registered: July 2009 |
Senior Member |
|
|
On 10.01.2012 10:08, Matthew Webber wrote:
> Our Java projects (mostly plugins) use a fairly standard layout, with
> Java source in src/ (and sometimes test/) directories, which get
> compiled to a bin/ directory. Obviously, the source code, but not the
> compiled classes, get checked in to the repository.
>
> Previously, we used subversion, and had svn:ignore set so that neither
> bin/ nor its contents were checked in to the respoitory. Hence there
> is no bin/ in the repository at all.
>
> We're moving to Git, so I'm reviewing the way we do things. What's best:
>
> (1) Don't have bin/ in the respository (specified by .gitignore in the
> project parent directory)
You should add
/*/bin/
in order to avoid that some random 'bin' folder gets excluded. Storing
an empty 'bin' folder doesn't buy you anything.
Dani
> OR
> (2) Check an empty bin/ in the respository (empty except for a
> .gitignore in the bin/ directory)
>
> Is one way better than the other, or is it just a case of personal
> preference? I'm leaning towards (2).
>
> Thanks
> Matthew
>
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03006 seconds