Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

AirCodea - AirCode in Codea

Hello everyone!

AirCodea is my attempt to reproduce AirCode in Codea.
It's actually a prototype with some ideas that are not fully implemented.
It runs a web server based on expressLua (my partial implementation of expressJS but in Lua) with coroutines.
You can fork this project to create your own AirCodea or to contribute to the main project.

Some additional features compared to AirCode:
- You can play/pause (if you use the update callback), enable/disable autoplay and autosave
- Alt-s to save the project (only useful if autosave mode is disabled)
- Alt-r to restart the project
- Alt-w to remove the current project tab

The autoplay don't restart entirely the project, in other words, it doesn't run again the setup function, but all others variables and functions are updated.

- only project names without spaces, accents and special characters like '_' works for now
- only projects that you have created are availables

Don't use it on projects that haven't backup ! Stability is not well tested yet. So don't hesitate to duplicate your projects before using AirCodea for now.

In this thread, you can also list the features that you want or dream about.

examples of the next features/changes list :
- maintain good tab order order on client, change tab order (, scroll horizontaly if there is a lot of tabs)
- better projects list
- better editor ui (create/delete tab, ...)
- create/delete projects
- replace monaco editor with codemirror
- version control system integration (github)

Have a good day!



  • Posts: 24
    Cool thanks ! I’ll test it soon and contribute if I can !
  • edited July 7 Posts: 1,226

    @HyroVitalyProtago - just had a quick look at AirCodea and looks neat. Nice editor. Can you get the icons up for the file?

    Hit an early problem - ran one of my developing projects and it fired up an error for the following line:

    if instW < 32 then

    Error was "Main:75: type 'userdata' is not supported by JSON."

  • Hey @Bri_G !

    Sorry, but I don't understand your question about the icons :/
    If it's about icons in the buttons, you can keep your mouse over it to have a tooltip of what it does. If it's about projects page, icons of each project will be added, but it's not a main feature for now and I'll have to redo the projects page anyway.

    For your early problem, it's maybe because you read something in your project like local data, and I haven't encapsulated all this functions in the env to run it on your real codea project (for the moment, storage functions don't works for project). Or it's maybe a problem with the line before or after (lua isn't really precise in its line errors detection). If I can see the code of the main file, maybe I can found the problem.

  • Posts: 1,226

    @HyroVitalyProtago - I was referring to the project page icons. It would be nice but not a priority.

    I think the error may be as a result of a dependency file being included, does AirCodea deal with that in you released version?

    The dependency includes a table of data, is that read in by Json?

  • @Bri_G Yep, I will include icons later on the projects page ;)

    Right, I also doesn't include dependencies at this time, I'll add it to my main list of features!

  • Posts: 1,226

    @HyroVitalyProtago - more feedback. Just logged onto AirCodea again and whilst logging on (using Firefox on Mac) I typed in in the address field - gave the usual options but on pressing the enter key AirCodea was connected without specifying the port?

    Also AirCodea seemed to keep the port open even when I had exited it on the iPad.

    Previous issue - regarding dependencies, the error did not disappeared when I removed the dependency and incorporated the dependent code in a new Tab in the Codea project.

    Ran a number of my projects fine then seemed to hang up, locked out and had to restart the project and web page.

    Love the editor - still early days. Hope this feedback helps.

  • edited July 9 Posts: 292

    @Bri_G Thanks a lot for the feedbacks!

    • You don't need to write the port because it's the default HTTP one. I found that more user-friendly.
    • To close the socket directly, there is a button Close in parameters sidebar. @Simeon is there a way to have a onClose fallback that is called when a project is closed?
    • For the dependency things, it's strange that incorporate files directly in the project doesn't resolve the things... did you use a storage function like readText, readProjectData or readImage? I haven't handle those functions for now if the assetKey begins with Project:.

    Ran a number of my projects fine then seemed to hang up, locked out and had to restart the project and web page.

    Don't know why, I needs to try this kind of project to see if I can identify the problem...

    I forgot to say it in the initial message, but it's possible to create a new tab with alt-t, write the tab name, then press enter.

  • Posts: 1,226

    @HyroVitalyProtago - just tried running my project above with the data table incorporated in a tab. It came back with the same problem - not dependency related.

    Now think it may be due to me using emoji tables as in the following recent link:

  • @Bri_G Thanks again for the feedback! I will try to use emojis to see if its related.

Sign In or Register to comment.