hello, i am pretty much new to git and only know how to use it to set up a local repo in conjuction with drush-git-backup. i used dgb to backup my site before starting the 3.2 --> 3.3 upgrade. but now I come to find out there is a .gitignore file in the commons hierarchy that caused most of the commons files to not get added to my repo. which makes me sad. I think this was my bad in not having enough experience to check for nested .gitignore files and for not knowing how to confirm that all files really were added as i assumed.

but i'm submitting this issue because i'm not sure why the .gitignore file is included in the commons distro (which i got from the .tar.gz release, not via git), and just in case it's an oversight. or in case other folks run into the same issue of thinking they have their code backed up and really it's not.

Here is the content of profiles/commons/.gitignore I do not use 'drush make' so i don't really know in what cases this would be useful, compared to my case where it was harmful.

% cat profiles/commons/.gitignore
      1 # Ignore files and folders that may end up in profiles/commons as part of the
      2 # a drush make build.
      3 PATCHES.txt
      4 libraries
      5 modules
      6 themes

Comments

japerry’s picture

Status: Active » Reviewed & tested by the community

Yup. This is a problem and we've decided to revert the changes in #2040071: Add .gitignore for contributed projects

People who are contributing to commons will need to instead add the files you listed above into '.git/info/exclude' locally.

japerry’s picture

Status: Reviewed & tested by the community » Fixed
WebSinPat’s picture

Thanks @japerry.

for any other newbies out there on why gitignore files are included at all by default, I found this issue informative: #917492: Add a sensible .gitignore file

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.