8000 Ignore backup files of hooks by hackebrot · Pull Request #768 · cookiecutter/cookiecutter · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Ignore backup files of hooks #768

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

Merged

Conversation

hackebrot
Copy link
Member

Resolve #767

@hackebrot hackebrot added bug This issue/PR relates to a bug. needs-review PR Only: This PR require review from other developer labels Jun 27, 2016
@codecov-io
Copy link
codecov-io commented Jun 27, 2016

Current coverage is 100%

Merging #768 into master will not change coverage

@@           master   #768   diff @@
====================================
  Files          13     13          
  Lines         584    585     +1   
  Methods         0      0          
  Messages        0      0          
  Branches        0      0          
====================================
+ Hits          584    585     +1   
  Misses          0      0          
  Partials        0      0          

Sunburst

Powered by Codecov. Last updated by 964e5ae...9f9b1a2

@michaeljoseph
Copy link
Contributor
michaeljoseph commented Jun 27, 2016

Nice! 👍


if not filename.endswith('~') and basename in _HOOKS:
hooks[basename] = os.path.abspath(os.path.join(hooks_dir, f))
return hooks
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not really a fan of this existing implementation- the caller knows which hook it's looking for, so it's weird that we iterate through all the hook files on pre- and post-...

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

100% agreed!

@hackebrot
Copy link
Member Author

Let's refactor find_hooks() in a separate branch.

@michaeljoseph
Copy link
Contributor

🍰 Cool to merge post CI.

@michaeljoseph michaeljoseph merged commit 097759b into cookiecutter:master Jun 27, 2016
@hackebrot hackebrot deleted the ignore-backup-files-of-hooks branch June 27, 2016 21:09
michaeljoseph added a commit to michaeljoseph/cookiecutter that referenced this pull request Jun 27, 2016
@hackebrot
Copy link
Member Author

Thanks for the review and the merge @michaeljoseph! 🍰

@michaeljoseph
Copy link
Contributor

You make it my pleasure @hackebrot 😻

terryjbates pushed a commit to terryjbates/cookiecutter that referenced this pull request Jul 23, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue/PR relates to a bug. needs-review PR Only: This PR require review from other developer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0