Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add generated files to .gitignore when selecting Gulp #3500

Merged
merged 2 commits into from
Dec 29, 2021

Conversation

mpoli
Copy link
Contributor

@mpoli mpoli commented Dec 28, 2021

Add project.css and project.min.css to .gitignore when js_task_runner == ' Gulp'. These files are generated automatically in this configuration and, as such, mess up git commit periodically.

Description

cookiecutter-django's default behavior when selecting Gulp as JS Task Runner will result in project.css and project.min.css to be regenerated automatically and periodically.

These auto-generated files should not be part of the repo, as they will mess up version control development activities.

Checklist:

  • I've made sure that tests are updated accordingly (especially if adding or updating a template option)
  • I've updated the documentation or confirm that my change doesn't require any updates

Rationale

According to the docs, selecting Gulp as the JS Task Runner will cause the installation to recompile the SASS project.scss file into project.css (and presumably also project.min.css).

The project.css and project.min.css will show up as changed periodically and mess up development by forcing the user to discard in development or unnecessarily committed to the project repo.

Fix #2857

when js_task_runner == ' Gulp'. These files are generated automatically in this configuration
and as such, mess up git commit periodically.
@browniebroke
Copy link
Member

The build seems broken due to an unrelated issue: PyCQA/isort#1874

More runtime generated files should be ignored to version control.

Co-authored-by: Bruno Alla <browniebroke@users.noreply.github.com>
@browniebroke browniebroke merged commit cf94dd4 into cookiecutter:master Dec 29, 2021
@browniebroke
Copy link
Member

Thanks!

@browniebroke browniebroke changed the title Add project.css and project.min.css to .gitignore Add generated files to .gitignore Dec 29, 2021
@browniebroke browniebroke changed the title Add generated files to .gitignore Add generated files to .gitignore when selecting Gulp Dec 29, 2021
@mpoli mpoli deleted the project.css-in-.gitignore branch December 31, 2021 15:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[feature request] Add generated files to .gitignore
2 participants