Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

change path to corona? (so support Corona 2.0 and non-2.0 builds)
Started by greg886 Nov 20 2013 08:08 PM

13 replies to this topic
[TOPIC CONTROLS]
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

greg886

[GLOBAL: userInfoPane.html]
greg886
  • Pro
  • PipPipPipPipPipPip
  • 867 posts
  • Jedi

is there a way to config the editor (or project) to either the (a) new Corona builds with Graphics 2.0 for projects that are using this and (b) the older builds for projects that need this.  i.e. Had to rename my exiting Corona install on mac before installing the latest 2.0.  Want to be able to hit CMD-B and build the project with the project knowing which Corona app install to use.



[TOPIC: post.html]
#2

greg886

[GLOBAL: userInfoPane.html]
greg886
  • Pro
  • PipPipPipPipPipPip
  • 867 posts
  • Jedi

PS I tried by renaming both versions of corona and using a symbolic link. Works for textMate, however for sublime it works the first time bit subsequently fails. Ie when using CMD-D....

[TOPIC: post.html]
#3

Perry Clarke

[GLOBAL: userInfoPane.html]
Perry Clarke
  • Corona Staff
  • 362 posts
  • Jedi

The next release provides a mechanism to specify the preferred location of the Corona Simulator using a preference.

 

Would it be desirable to set this on a per project basis?



[TOPIC: post.html]
#4

greg886

[GLOBAL: userInfoPane.html]
greg886
  • Pro
  • PipPipPipPipPipPip
  • 867 posts
  • Jedi

Yes please

[TOPIC: post.html]
#5

Perry Clarke

[GLOBAL: userInfoPane.html]
Perry Clarke
  • Corona Staff
  • 362 posts
  • Jedi

I'm thinking a build.settings entry like:

settings =
{
    corona_sdk_simulator_path = "/arbitrary/path/to/a/Corona Simulator"

    ...



[TOPIC: post.html]
#6

greg886

[GLOBAL: userInfoPane.html]
greg886
  • Pro
  • PipPipPipPipPipPip
  • 867 posts
  • Jedi

if it's per project that sounds ok to me Perry - I'm using sym links for the moments with a batch file to change it back and forth



[TOPIC: post.html]
#7

richard9

[GLOBAL: userInfoPane.html]
richard9
  • Pro
  • PipPipPipPipPipPip
  • 1,113 posts
  • Jedi

Eagerly awaiting this; had to stop testing the official Corona package because I need to keep the G2.0 builds seperate.



[TOPIC: post.html]
#8

Perry Clarke

[GLOBAL: userInfoPane.html]
Perry Clarke
  • Corona Staff
  • 362 posts
  • Jedi

The new release of Corona Editor that allows the Simulator to be set on a per project basis is up: http://coronalabs.com/products/editor



[TOPIC: post.html]
#9

AlanPlantPot

[GLOBAL: userInfoPane.html]
AlanPlantPot
  • Starter
  • PipPipPipPipPipPip
  • 733 posts
  • Jedi

When I set my path in build.settings, I get an error message saying "Cannot find executable Corona Simulator at path '/Applications/CoronaSDK2.0/Corona\ Simulator.app/Contents/MacOS/Corona Simulator'"  

 

Do I need to do something differently on OSX to get this to work? I got the path name by dragging the Simulator icon to the Terminal, so it should be correct. I've also tried changing "\ Simulator.app" to "/Simulator.app" without any luck.



[TOPIC: post.html]
#10

AlanPlantPot

[GLOBAL: userInfoPane.html]
AlanPlantPot
  • Starter
  • PipPipPipPipPipPip
  • 733 posts
  • Jedi

Scratch that - having looked more closely at the path, I've realised that:

"/Corona\ Simulator.app/"

just needed to have the backslash removed to change it to:

"/Corona Simulator.app/"



[TOPIC: post.html]
#11

richard9

[GLOBAL: userInfoPane.html]
richard9
  • Pro
  • PipPipPipPipPipPip
  • 1,113 posts
  • Jedi

I admittedly don't understand how this is supposed to work. Maybe the documentation needs to be expanded a bit?

 

1. Removed Corona Editor and reinstalled via Package Control (now shows 1.0 under List Packages)

2. I added this line within the settings{} in build.settings:

corona_sdk_simulator_path = "/Applications/CoronaSDK 2100/Corona Simulator.app/Contents/MacOS/Corona Simulator",

 

Upon trying to build, there is no error message regarding the simulator, even if I completely change the path to something nonsensical. And the specified build is not loaded; only the default Corona is (which obviously causes errors when you jump back from 2076 to 1259)

 

Additionally, if you try to edit the settings for Corona Editor, the file is read-only and cannot be modified at all within ST3. Not sure why that has been set.



[TOPIC: post.html]
#12

richard9

[GLOBAL: userInfoPane.html]
richard9
  • Pro
  • PipPipPipPipPipPip
  • 1,113 posts
  • Jedi

On further exploration:

 

FN+CMD+F10: Runs the version of Corona specified in build.settings

CMD+B: Runs the default version of Corona only.

 

Is this fixable?

 

(Also; the docs mention a way to just globally set the build of Corona to use...but not where to put it. What file does it go in? What does it look like?)



[TOPIC: post.html]
#13

greg886

[GLOBAL: userInfoPane.html]
greg886
  • Pro
  • PipPipPipPipPipPip
  • 867 posts
  • Jedi

haven't had a chance to try yet, but definitely would like CMD+B to run the version of Corona defined for the project you are editing.. (i.e. per project setting first, then if not defined the default setting)



[TOPIC: post.html]
#14

Perry Clarke

[GLOBAL: userInfoPane.html]
Perry Clarke
  • Corona Staff
  • 362 posts
  • Jedi

Be sure to use Run Project to have Sublime Text pick up the build.settings or preference specified version of Corona Simulator.  There are some issues making the Build command (Cmd+B) work this way which have not been resolved yet (but it is intended to do so, at least for Sublime Text 3).  Run Project also does a better job of finding main.lua no matter how the project is laid out on disk.




[topic_controls]
[/topic_controls]