Drupal-project: Add services.yml and .DS Store in .gitignore.

Created on 24 Jul 2018  Â·  3Comments  Â·  Source: drupal-composer/drupal-project

These files are created while development or working on Mac, we should add these to .gitignore.

Most helpful comment

If this is messing with your development workflow, I highly recommend creating a global excludes file on your local development environment which will solve this problem for all git repositories on your machine:

git config --global core.excludesfile ~/.gitexcludes
echo ".DS_Store  
.idea  
*.sublime-*" >> ~/.gitexcludes

I'm not a maintainer of this project so this is just my personal solution to this problem. I also don't see why people commit things like ".idea" (the Phpstorm IDE project metafile) to an open source project's .gitignore, when that is clearly environment and developer specific configuration that each dev should be responsible for ignoring on their own. I'm of the opinion (however unpopular) that only files that are directly related to or generated by the application itself should be added to a .gitignore.

Here is my ~/.gitexcludes, maybe you can use it...

https://github.com/jameswilson/dotfiles/blob/master/.gitexcludes

All 3 comments

If this is messing with your development workflow, I highly recommend creating a global excludes file on your local development environment which will solve this problem for all git repositories on your machine:

git config --global core.excludesfile ~/.gitexcludes
echo ".DS_Store  
.idea  
*.sublime-*" >> ~/.gitexcludes

I'm not a maintainer of this project so this is just my personal solution to this problem. I also don't see why people commit things like ".idea" (the Phpstorm IDE project metafile) to an open source project's .gitignore, when that is clearly environment and developer specific configuration that each dev should be responsible for ignoring on their own. I'm of the opinion (however unpopular) that only files that are directly related to or generated by the application itself should be added to a .gitignore.

Here is my ~/.gitexcludes, maybe you can use it...

https://github.com/jameswilson/dotfiles/blob/master/.gitexcludes

I do the same as @jameswilson — it's crazy that we probably have multiple GB worth of .gitignore files across millions of OSS projects ignoring system- and user-specific files which should really be ignored on the user level, and not in projects.

Same here. These files are not project related so they don’t belong in the repo. Just create a global .gitignore once and you never have to worry about these files anymore.

Ignoring services.yml is not necessary if you use development.sevices.yml for local development. https://www.drupal.org/node/2598914

Was this page helpful?
0 / 5 - 0 ratings