cognitect-labs / vase

Data driven microservices
Eclipse Public License 1.0
373 stars 42 forks source link

Generating vase template project with a kebab-case project name results in inconstant naming of the service.edn file #89

Open CalebMacdonaldBlack opened 6 years ago

CalebMacdonaldBlack commented 6 years ago

Description

Generating a vase template project with a kebab-case project name results in inconstant naming of the service.edn file. For example, running lein new vase foo-bar creates the file resources/foo-bar_service.edn with hyphens and underscores.

I'm aware that namespaces must be separated by hyphen and have a corresponding filename separated by an underscore in order to work at all. And that the service.edn is just a file that is read and is not required to follow that patten at all and will work anyway.

I do believe it should be consistent though and sanitising the namespace as is done with clj filenames will make this file look a little less strange when generated.

Expected Behavior

Running lein new vase foo-bar creates the file resources/foo_bar_service.edn

Actual Behavior

Running lein new vase foo-bar creates the file resources/foo-bar_service.edn

I can submit a PR to fix this if this change is wanted.

mtnygard commented 6 years ago

A PR would be most welcome. But since EDN files don't need to be underscored like classnames, I'd rather see resources/foo-bar-service.edn.