Quick Links: Download Gideros Studio | Gideros Documentation | Gideros Development Center | Gideros community chat | DONATE
New version: ZeroBrane Studio IDE with color schemes, internationalization, documentation, and more — Gideros Forum

New version: ZeroBrane Studio IDE with color schemes, internationalization, documentation, and more

paulclingerpaulclinger Member
edited December 2012 in Announcements
A new version of the IDE has been released and is available at http://studio.zerobrane.com/. For those starting with it, I posted a "getting started" guide (http://studio.zerobrane.com/doc-getting-started.html), an FAQ (http://studio.zerobrane.com/doc-faq.html), and other documentation (http://studio.zerobrane.com/documentation.html). I also added a very simple live coding example using Gideros (http://notebook.kulchenko.com/zerobrane/gideros-live-coding-a-simple-example).

It is now possible to pause the debugger when running as scratchpad, inspect values and execute commands in the remote console, and then continue your live coding session.

Among other changes, the last version added live coding support for Moai as well as debugging and auto-complete integration for Corona. Enjoy and let me know if you run into any issues. Thank you for all the feedback and improvement ideas. Paul.
Tagged:
+1 -1 (+7 / -0 )Share on Facebook

Comments

  • OZAppsOZApps Guru
    edited December 2012
    @Paul Looks good... (ZeroBrane Studio, I mean ;) )
    twitter: @ozapps | http://www.oz-apps.com | http://howto.oz-apps.com | http://reviewme.oz-apps.com
    Author of Learn Lua for iOS Game Development from Apress ( http://www.apress.com/9781430246626 )
    Cool Vizify Profile at https://www.vizify.com/oz-apps
  • I think I asked this before, but don't remember the answer.
    Is it possible in ZeroBrane to use the print function to output info anywhere where i can read it? (the 'output' window seems to be more logical, but it does not work for me)
    thanks
  • @keszegh, when you debug your Gideros application, all the output you "print" should appear in the Output window.

    What you say "it doesn't work", do you mean it doesn't appear there? Can you check interpreters/gideros.lua file to make sure it has 'redirect = "c"' option set for the debugger? If not, you may want to grab the latest version of that file. If the fragment is there, please provide more details (the platform, ZBS version) or a code fragment I can test with. Thanks.
  • i'm now away from home but will check in a week. thanks
  • @paulclinger, my problem is indeed that 'print' does not print into the output window, or anywhere else. it is still not working, i have this line in gideros.lua:
    if rundebug then DebuggerAttachDefault({redirect = "c"}) end

    so that seems fine. otherwise the test file is project with a sole main.lua file containing:
    print("test")

    and the output windows has this only(I changed the paths to **):
    Program starting as '"C:\Program Files (x86)\Gideros\GiderosPlayer.exe"'.
    Program 'GiderosPlayer.exe' started in '**\printtest' (pid: 1136).
    Starting the player and waiting for the bridge to connect at 'C:\Program Files (x86)\Gideros\Tools\gdrbridge.exe'.
    Starting project file '**\printtest.gproj'.
    Program completed in 2.52 seconds (pid: 1136).

    it is on win7 and the latest 0.34 zb version, before i deleted the whole zb directory with the previous install so it is a clean install in this sense (although registry values were not cleared, as it immediately knew which was the latest project i was working on etc).
  • paulclingerpaulclinger Member
    edited February 2013
    @keszegh,

    It seems like you "run" your project instead of debugging it. Print redirect only works when you run it under the debugger.

    Try with:
    require("mobdebug").start() --<-- make sure to start the debugger
    print("test")
    and then use "Project | Start Debugging". "test" should be printed to the Output window.

    > registry values were not cleared, as it immediately knew which was the latest project i was working on etc

    These are saved in a configuration file outside of the ZBS directory; that's why the new install picked up the current configuration (http://studio.zerobrane.com/doc-faq.html#how_do_i_restore_default_configuration_for_recent_files_projects_and_editor_tabs).
  • @paulclinger
    thanks, i tried both run and start debugging, but it seems that the important thing i did not do before is adding the line:
    require("mobdebug").start()

    after adding this everything works fine. probably it is somewhere in some help written that this line is needed, sorry for not paying attention. on the other hand maybe when one starts debugging then this line should be considered to be there by the compiler even if it is not there? it is a bit strange that you need to add this line, especially when i switch from the gideros ide back and forth, which does not work when this line is there.

    although this way you can put this line anywhere in your code, which maybe useful for something i don't know about.

    in any case, thanks again. i was suffering with the gideros ide freezing on me (because of avg probably), so using zerobrane became the only option - and now i start to enjoy its added value.
  • > it is a bit strange that you need to add this line, especially when i switch from the gideros ide back and forth, which does not work when this line is there.

    @keszegh, agree, but my preference is to keep things like this explicit for several reasons. I know that some other IDEs modify your source file behind the scenes and I considered doing so, but using this way it works with any method launching the script: you can launch it from ZBS, from Gideros Player or from the device (may need to add IP address if it's from a different computer). If there was a way to pass the information to the player without modifying the source code, I'd probably use it.
  • @paulclinger, is there any way to prevent the editor from jumping to the mobdebug line when i start debugging? it is annoying to always switch back to the file where i was working. also there could be a play button which works like pressing the regular play button twice (once normal and once when it arrives to the mobdebug line) - maybe these are too much gideros specific, but would make life easier.

    otherwise thanks for the nice ide.
  • > is there any way to prevent the editor from jumping to the mobdebug line when i start debugging?

    @keszegh, I just pushed several changes that may resolve this issue for you(https://github.com/pkulchenko/ZeroBraneStudio). First, the debugging for gideros scripts should start immediately, which was something that other people asked about too (one can still turn it off with debugger.runonstart = false), and second, it won't stop in main.lua anymore, but will only stop on breakpoints (or when you use "break" in the application). You don't even need to have main.lua open.

    It should work with other features (like live coding). Please let me know if this works for you and it can make it into the release I plan for tomorrow. Thanks. Paul.
  • @paulclinger, it works as you state, it is much faster to debug now. thanks

    just in case, where should be the line "debugger.runonstart = false" in case i want to turn off debugging? i found that it should be in cfg\user.lua like any other user config setting, right? this may be useful for some people.
  • keszeghkeszegh Member
    edited February 2013
    btw, is the stack window working with gideros?
    whenever i reach a breakpoint i always see inside only such an error:
    Error: [string "do local_={{{"init","mycounter.lua",3,4"L..."]:1: attempt to index field '?' (a nil value)

    edit: it works in some lua files for me but in some others i get the above error
  • @keszegh,

    > where should be the line "debugger.runonstart = false" in case i want to turn off debugging? i found that it should be in cfg\user.lua like any other user config setting, right?

    That's correct.

    > it works in some lua files for me but in some others i get the above error
    > whenever i reach a breakpoint i always see inside only such an error:

    Can you send me the fragment you are debugging to allow me to reproduce it locally (email to paul at kulchenko dot com)? There is possibly a bug in the serializer that serializes the stack trace, although I haven't seen any issues like this in my Gideros debugging (or in other cases).
Sign In or Register to comment.