How to migrate an application to Levure framework

A place to discuss Version Control in LiveCode

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
mrcoollion
Posts: 709
Joined: Thu Sep 11, 2014 1:49 pm
Location: The Netherlands

How to migrate an application to Levure framework

Post by mrcoollion » Mon Apr 13, 2020 12:43 pm

Hello LC friends,

I am looking into using the Levure framework to develop my Applications with. At this moment I am working on an application with already a few thousand script lines and many commands, functions in Cards and some SubStacks.
The question is : How best can I migrate this application into the Levure Framework and continue working with it.

Regards,

Paul

trevordevore
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1005
Joined: Sat Apr 08, 2006 3:06 pm
Location: Overland Park, Kansas
Contact:

Re: How to migrate an application to Levure framework

Post by trevordevore » Mon Apr 13, 2020 2:51 pm

Hi @mrcoollion,

Currently there isn't a guide for migrating an existing project over. But we can use this thread to guide you through the process and then put what we learn up on the wiki. Below is an overview of where you can start with links to relevant wiki pages. Ask for clarification where needed and we can work through it.

Assuming you have already created a Levure app, I think the first thing I would do is separate the existing app based on the folders that Levure creates in the ./app folder. The following link lists the app folder structure:

https://github.com/trevordevore/levure/ ... App-Folder

You can start with the libraries, frontscripts, and backscripts folders. All libraries that your app uses can be moved out into individual stack files and placed in the libraries folder. They will automatically be loaded and `put in use` when your Levure app is opened. Same goes for the frontscripts and backscripts folder.

Next, you would move the stack(s) with the user interface for your app into the `ui` folder. Here are the docs:

https://github.com/trevordevore/levure/wiki/ui

Don't worry about moving scripts out into script only stacks at this point. You just want to get your application working within Levure first.

Once you've moved stacks into the ui folder you are probably ready to update the app.livecodescript stack with the code necessary to open the correct stack when the application opens.This can be done by adding a go to stack line to the OpenApplication handler in app.livecodescript.

https://github.com/trevordevore/levure/ ... codescript
Trevor DeVore
ScreenSteps - https://www.screensteps.com

LiveCode Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode
LiveCode Builder Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode-builder

mrcoollion
Posts: 709
Joined: Thu Sep 11, 2014 1:49 pm
Location: The Netherlands

Re: How to migrate an application to Levure framework

Post by mrcoollion » Tue Apr 14, 2020 7:12 am

Thanks for the reply Trevor :D

I will try to move my application into the Levure Framework asap and keep you posted.

PS. maybe an idea to have a specific Levure Framework Channel in 'Third Party extension support' ?

Regards,

Paul

tim2RZ
Posts: 6
Joined: Tue Mar 10, 2020 12:27 am

Re: How to migrate an application to Levure framework

Post by tim2RZ » Tue May 12, 2020 11:24 am

trevordevore, thanks for explanation.

Post Reply

Return to “Version Control”