I'm currently using Eclipse for a project and also the Play! Framework. I wanted to add buttons to this dropdown in Eclipse
that say :
Play Start myfile1
play stop myfile1
play start myfile2
play stop myfile2
I have it for one project but not a new project I am starting. I'm not setting them up right because i keep getting an error:
'Launching play1 start filename' has encountered a problem.
Exception occurred executing command line.
I don't know how I'm messing it up. Something to do with where the locations I'm setting? Here is the first screen in configurations that i am trying and it isn't working. Help would be appreciated. Thanks!
I generally have Play running in a separate console window. Do play start and then play run. Leave it running all all. The play app is now available at localhost:9000. Then you can start Eclipse and start coding. Play will re-compile and reload the app on-the-fly. Generally you don't have to stop play (type ctrl-D) unless you make a substantial change.
OK! I have the solution.
1) Click on the dropdown play button with briefcase
2) click External Tools Configurations.
New Configuration underneath "Program"
Name it. ie play start filename
Location: ${play}
click Variables
Edit Variables
New Variable
Variable Name: play
Value: D:\\play-1.2.5\\play.bat (or wherever you have your play.bat file.)
Ok, Ok, ok, go back to main External Tools Configurations screen.
Working Directory: ${workspace_loc}
Arguments: start filename
Switch tab to "Common" tab.
Click the radial button for Shared file and go to your app file:
ie \\filename
Check "External Tools"
Every other default should be fine. Click apply and it should start your play application. Do the same for "stop" but replace "start" with "stop."
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.