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

feat: add underscorize helper #9

Closed
wants to merge 1 commit into from
Closed

feat: add underscorize helper #9

wants to merge 1 commit into from

Conversation

ivokub
Copy link

@ivokub ivokub commented Dec 4, 2024

Adds a helper function to convert hyphens to underscores.

@gbotrel
Copy link
Collaborator

gbotrel commented Dec 5, 2024

(can also be added through options directly without modifying bavard but why not :) ))

@ivokub
Copy link
Author

ivokub commented Dec 9, 2024

Oh, didn't know that. Using option is definitely better, doesn't change other generated files. But I'll keep this PR for now, maybe it is useful in the future. I tested and manually overriding the template function works also nicely (so both adding "underscorizer" as an option to bavard.GenerateWithOption and upgrading bavard), so should be backwards compatible. Lets sync if we keep this PR or close it.

@ivokub
Copy link
Author

ivokub commented Dec 10, 2024

Not needed anymore.

@ivokub ivokub closed this Dec 10, 2024
@ivokub ivokub deleted the feat/underscorize branch December 10, 2024 22:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants