Skip to content
This repository has been archived by the owner on Mar 26, 2018. It is now read-only.

.Coffee file #329

Closed
jacobharasimo opened this issue Aug 19, 2013 · 9 comments · Fixed by #367
Closed

.Coffee file #329

jacobharasimo opened this issue Aug 19, 2013 · 9 comments · Fixed by #367

Comments

@jacobharasimo
Copy link

after i set up webapp and angular using yeoman on my windows7 pc i find that running yo angular:directive myDirective produces .coffee files. I know you can do yo angular:directive myDirective --coffee to turn this on but how do i turn it off or force .js files?

@eddiemonge
Copy link
Member

do you have any coffee files in your app/scripts folder? if you do thats why its using the coffee option

@jacobharasimo
Copy link
Author

Can I add some switch to force javascrip. It has a --coffee can you make a
--no-coffee or --js
On 2013-08-19 5:29 PM, "Eddie Monge Jr." [email protected] wrote:

do you have any coffee files in your app/scripts folder? if you do thats
why its using the coffee option


Reply to this email directly or view it on GitHubhttps://github.com//issues/329#issuecomment-22905763
.

@eddiemonge
Copy link
Member

try --coffee=false

@jacobharasimo
Copy link
Author

I did. No work
On 2013-08-19 5:46 PM, "Eddie Monge Jr." [email protected] wrote:

try --coffee=false


Reply to this email directly or view it on GitHubhttps://github.com//issues/329#issuecomment-22907052
.

@passy
Copy link
Member

passy commented Aug 24, 2013

As soon as you have .coffee files in your scripts folder, the generator assumes your project is a CS project:

if (!this.options.coffee &&

@jacobharasimo
Copy link
Author

yes, its a bug. --coffee=false needs to be repaired as I have run into situations where i need to generate .js not .coffee

specifically some devs don't know coffee and some do... so some write it and some don't. in this case we eventually translate what the other devs write (generally contractors) back to js as simply a higher % of the the staff understand it.

@eddiemonge
Copy link
Member

honestly that sounds like a bug in your process

@jacobharasimo
Copy link
Author

I admint the process is not perfect. however the point is, even as you said, --coffee=false should work. it doesn't. so why the process is not 100% clearly this code has a bug as --coffee=false should work.

if you bring up the options for this is says --coffee defaults to false... yet that's also wrong as --coffee only defaults to false if there is no .coffee file existing... so there is some errors with the program and its documentation. --coffee=false should provide and override for this.

@andersoyvind
Copy link

It's probably a nice feature, that after creating one .coffee, the --coffee option becomes unnecessary.

In my case I create basic classes using coffeescript, but aren't into its syntax yet, so I'd like to use something like --coffee=false. Which of now doesn't work.

Alternatively, javascript files could be produced until the --coffee option is used. No hidden assumptions in the tool.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants