seting up coffeeScript project to get compiled .js files
I'm setting up my first coffeeScript project. For this moment I already can run my .coffee, but I want it to generate appropriate .js file after each build. The structure of project is:
Coffee
\.idea
\cs
-test.coffee
\js
Coffee.iml
my test.coffee is in \cs, and I want test.js in \js. In Run/Debug configurations, in Node JS section there is "coffeeScript perameters:". As I understand there must be something like "--output js --compile cs" or "coffee --output js --compile cs" so it compile recursively all in \cs folder and output all .js in \js. But it dosen't
Fields "Node Parameters" and "Application Parameters" are empty, "Path to Node App JS File" set to "cd\test.coffee"
So what must be those parameters?
Thank you
请先登录再写评论。
There is no built-in facility to get compiled js files yet
Run configuration parameters is intended to be used for launching NodeJS
application from CS sources
On 4/10/2012 6:58 PM, Aleksey Bobyr wrote:
>
>
>
>
>
>
>
>
>
>
>
>
Well, case is that once it worked! I make such configuration, that test.js appears in \js. But than I broke it and can't reproduce any more
:( . Changes was only in Run configuration in Node JS section.
Yes, and I'm using NodeJS: http://www.jetbrains.com/idea/webhelp/coffeescript-support.html I just cann't run coffeeScript without NodeJS if I dont want to use some online compilators. At least I dont know how to do that.
And here http://www.jetbrains.com/idea/webhelp/run-debug-configuration-node-js.html said that
so if it is not place for this http://coffeescript.org/documentation/docs/command.html coffeeScript parameters, than what does this field for? (about argument for --compile I read in "The Little Book on CoffeeSrcipt". Would be very glad if work even without it)
Upd: from coffeescript documentation which is provide with corrent coffeescript source:
So finaly I've done it!
The problem is that content of "CoffeeScript parameters" feald do nothig. Write there "elephant", IDEA just ignore it.
What we need to setup Run/Debug Configuration:
- Desable "Ran with CoffeeScript plugin" checkmark
- In "Node Parameters" set ""YOUR_PASS_TO_COFFEESCRIPT_FOLDER\bin\coffee" -c -o js/"
so you get all .js files in /js folder in your project derectory (set any other if you want. C.O. :) )