mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-07-27 00:09:47 +03:00
Update post_gen_project.py
Add remove_project_css function to remove static/css/project.css in case a bundler is used.
This commit is contained in:
parent
98bcde07e7
commit
cc3ab07f2a
|
@ -105,6 +105,10 @@ def remove_vendors_js():
|
|||
if vendors_js_path.exists():
|
||||
vendors_js_path.unlink()
|
||||
|
||||
def remove_project_css():
|
||||
project_css_path = Path("{{ cookiecutter.project_slug }}", "static", "css", "project.css")
|
||||
if project_css_path.exists():
|
||||
project_css_path.unlink()
|
||||
|
||||
def remove_packagejson_file():
|
||||
file_names = ["package.json"]
|
||||
|
@ -462,6 +466,7 @@ def main():
|
|||
if "{{ cookiecutter.use_docker }}".lower() == "y":
|
||||
remove_node_dockerfile()
|
||||
else:
|
||||
remove_project_css()
|
||||
handle_js_runner(
|
||||
"{{ cookiecutter.frontend_pipeline }}",
|
||||
use_docker=("{{ cookiecutter.use_docker }}".lower() == "y"),
|
||||
|
|
Loading…
Reference in New Issue
Block a user