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

name-as-module from stack new should be PascalCase #5376

Closed
tim2CF opened this issue Aug 27, 2020 · 4 comments
Closed

name-as-module from stack new should be PascalCase #5376

tim2CF opened this issue Aug 27, 2020 · 4 comments

Comments

@tim2CF
Copy link

tim2CF commented Aug 27, 2020

At the moment, command stack new hello-world $TEMPLATE_NAME generates project structure where name-as-module value is Helloworld instead of HelloWorld. Example

stack new hello-world \
  github:tkachuk-labs/nix-concur-replica \
  -p organization:tkachuk-labs \
  -p env-prefix:HELLO_WORLD \
  --resolver lts-14.27
@ardamose123
Copy link
Contributor

ardamose123 commented Sep 14, 2020

The Data.Text function toTitle (used to generate the name-as-module) has a bug: apparently, dashes are considered as letters for some reason. This has to be fixed in the text package.

@ardamose123
Copy link
Contributor

ardamose123 commented Sep 14, 2020

As a workaround, I can submit a PR that first converts the dashes to spaces, then applies the title-casing, then removes spaces instead of dashes.

@ardamose123
Copy link
Contributor

ardamose123 commented Sep 14, 2020

Submitted PR #5386 as a fix.

@tim2CF
Copy link
Author

tim2CF commented Sep 21, 2020

Thanks for the fix!

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

No branches or pull requests

2 participants