ioos / system-test

IOOS DMAC System Integration Test project
github.com/ioos/system-test/wiki
The Unlicense
7 stars 14 forks source link

.txt files #204

Closed duncombe closed 9 years ago

duncombe commented 9 years ago

This may be a dumb question, but I have git cloned system-test into my local drive and find the whole directory tree is covered in pip- or conda-requirements.txt files. Yet .gitignore includes the line .txt. All these files should be ignored. Where do they come from? And since requirements.txt is required, how come .txt is in the gitignore anyway?

birdage commented 9 years ago

@duncombe that might of been an addition i made in error the commit history looks like it was removed then i added it again https://github.com/ioos/system-test/commits/master/.gitignore

i generate a pull request in a few to change it

rsignell-usgs commented 9 years ago

From a quick look at: https://github.com/ioos/system-test/commits/master/.gitignore it seems @birdage erroneously added .txt files to .gitignore, then @kwilcox fixed the situation (removed .txt), and then @bobfrat erroneously added .txt again. Hopefully we are all on the same page now -- the .txt files should not be added to .gitignore, because they should be tracked and versioned!

birdage commented 9 years ago

@rsignell-usgs indeed, ill fix that in a few ticks

ocefpaf commented 9 years ago

IMHO I believe that .gitignore files should not be included in the repository. I like to use git status to show me all the files, even those marked to be ignored.

In addition sometimes people might disagree on what to ignore.

For example: I do not add the commonly ignore sdist and build directories in my python project. That way git status help me remember to remove them when building the code to test or when sending a new release to PyPI.

birdage commented 9 years ago

@ocefpaf i think the original reason for me adding it was that there were hundreds of txt files that get extracted from a zip file for the USGS notebook. They dont take up alot of space but there is so many that it cluttered up the git change list. instead of removing the txt files in the gitignore i should of identified the directory. i will make the change and commit.

ocefpaf commented 9 years ago

The files from this PR https://github.com/birdage/system-test/pull/1 ?

(Which BTW needs a review and a merge so we may move ahead with https://github.com/ioos/system-test/pull/177 :wink: )

That is another case why I like to leave the .gitignore outside the repository! I would add SSS-*.txt to my local .gitignore instead of the generic name directory data_files.

duncombe commented 9 years ago

Which leaves the question, why were the requirements.txt files included in the repo even though *.txt was in the .gitignore? Is that because someone has a custom .gitignore and was commiting them, whereas a person who accepted the .gitignore from the repo would not see them in git status, but still get them downloaded when doing git pull?

On Thu, Dec 4, 2014 at 11:01 AM, Filipe notifications@github.com wrote:

The files from this PR birdage#1 https://github.com/birdage/system-test/pull/1 ?

(Which BTW needs a review and a merge so we may move ahead with #177 https://github.com/ioos/system-test/pull/177 [image: :wink:] )

That is another case why I like to leave the .gitignore outside the repository! I would add SSS-*.txt to my local .gitignore instead of the generic name directory data_files.

— Reply to this email directly or view it on GitHub https://github.com/ioos/system-test/issues/204#issuecomment-65654266.

Dr. Christopher M. Duncombe Rae c deirdre.byrne@noaa.gov hristopher.duncombe.rae@noaa.gov Oceanographer / Data Scientist IOOS/NOAA, Suite 1225, 1100 Wayne Avenue, Silver Spring, MD 20910, USA Tel: +1-301-427-2450 Fax: +1-301-427-2073

ocefpaf commented 9 years ago

The why: system-test defined that we need a pip-/conda-requirement.txt for each notebook.

Maybe your question is how: git add -f conda-requirement.txt # -f == force

BTW I do have a custom .gitignore and I will not commit it because it would break the project for others (like what just happened).

birdage commented 9 years ago

@ocefpaf @duncombe :hand: my bad!

ocefpaf commented 9 years ago

@birdage No biggie! It is good to have some discussion about git, good practices and project management.

@duncombe I am closing this issue. You may re-open if you need any more clarification.

duncombe commented 9 years ago

@ocefpaf: so my surmise is correct, that someone else committed those files and I am getting them with the git pull despite the *.txt in the gitignore?

On Thu, Dec 4, 2014 at 11:32 AM, Andrew Bird notifications@github.com wrote:

@ocefpaf https://github.com/ocefpaf @duncombe https://github.com/duncombe [image: :hand:] my bad!

— Reply to this email directly or view it on GitHub https://github.com/ioos/system-test/issues/204#issuecomment-65659741.

Dr. Christopher M. Duncombe Rae c deirdre.byrne@noaa.gov hristopher.duncombe.rae@noaa.gov Oceanographer / Data Scientist IOOS/NOAA, Suite 1225, 1100 Wayne Avenue, Silver Spring, MD 20910, USA Tel: +1-301-427-2450 Fax: +1-301-427-2073

ocefpaf commented 9 years ago

@duncombe yes. The .gitignore only prevents the files from showing when someone type git status. Also, if you try to commit them you need to force commit.

duncombe commented 9 years ago

Thanks!

On Thu, Dec 4, 2014 at 11:44 AM, Filipe notifications@github.com wrote:

@duncombe https://github.com/duncombe yes. The .gitignore only prevents the files from showing when someone type git status. Also, if you try to commit them you need to force commit.

— Reply to this email directly or view it on GitHub https://github.com/ioos/system-test/issues/204#issuecomment-65661722.

Dr. Christopher M. Duncombe Rae c deirdre.byrne@noaa.gov hristopher.duncombe.rae@noaa.gov Oceanographer / Data Scientist IOOS/NOAA, Suite 1225, 1100 Wayne Avenue, Silver Spring, MD 20910, USA Tel: +1-301-427-2450 Fax: +1-301-427-2073