help-smalltalk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-smalltalk] What strategy to use when developing applications w


From: Nicolas Petton
Subject: Re: [Help-smalltalk] What strategy to use when developing applications with GST?
Date: Wed, 18 Aug 2010 16:43:04 +0200

Le mercredi 18 août 2010 à 07:15 -0700, ZuLuuuuuu a écrit :
> Hello,
> 
Hi Canol!

First of all, it's cool to have questions about Iliad, please keep
posting! :p
Also, I Cced to Iliad mailing list, I hope you don't mind.

> I was trying to port a sample Iliad application of mine from Squeak to GST.
> I'm having difficulty what steps I should follow while developing my app
> with GST (I know the question is not very explanatory yet).
> 
> Here is the first solution I applied, step by step:
> 
> 1) I wrote my widgets and application into their respective .st files.
> 
> 2) I want to test my application. So I created a remote GST using an image
> with Iliad pre-loaded:
> 
> gst-remote --server -I ../iliad.im
> 
> 3) I started the Swazoo Iliad server:
> 
> gst-remote -e "(Iliad.SwazooIliad startOn:8888) printNl"
> 
> 4) I created a file, which files in my other files:
> 
> gst-remote -e "(FileStream fileIn: 'MyFileIn.st') printNl
> 
> The problem with this approach is that I need to put
> 
> Namespace current: Iliad []
> 
> around all my classes to keep it organized. The good side of this approach
> is that it is easy :) Just keep doing step 4 when you modify a method. And
> if you do a modification like changing a class' or method's name or remove
> one completely, restart the remote GST and file in your MyFileIn.st again.
> So that you don't have unnecessary methods or classes on your running image.
> 
> Question 1: I guess this is not the way I should develop my applications?

If I understand you correctly, you use the Iliad namespace to develop
your application. You shouldn't do this, since your application is not
Iliad itself. It's also true for the IL prefix, it's supposed to be used
for Iliad classes only.

> 4) I created a package.xml with an appropriate content.

Better :)

> 6) Then loaded the package in with:
> 
> gst-remote -e "(PackageLoader fileInPackage: 'Iliad-More-MyApp') printNl"

Again, you should name your package differently, unless you plan to
contribute it to Iliad ;)

> Question 2: Is this the way how I should develop my application?

Yes, that's what I do at least, using star packages. 

> Question 3: When I modify something, I recreate the package and try to load
> the new package in, I guess it does not load it because it is already
> loaded. So my changes do not take effect. How can I force PackageLoader to
> load the new package in? There is a flag for it on gst-load but I couldn't
> figure out how can I apply it on my remote GST's image. I can stop the
> server, apply gst-load with force option but then my iliad.im will be
> permanently changed. I can create an image with different name but doing
> this every time I do a change didn't seem practical.

Here we have scripts to automatically rebuild the image and reload the
packages. There is one in Iliad in the scripts directory too.
http://github.com/NicolasPetton/iliad/blob/master/scripts/start



> The third solution would be to use gst-browser:
> 
> 1) Open gst-browser on an image with Iliad preloaded:
> 
> gst-browser -I "iliad.im"
> 
> 2) Start Swazoo Iliad server via
> 
> Iliad.SwazooIliad startOn:8888
> 
> 3) Create your application's classes and methods.
> 
> 4) Just go test your application on browser and see your modifications
> without doing any package loading.
> 
> The upside is that you can use "ILErrorHandler debugMode" to debug your
> application alive.
> 
> Question 4: "ILErrorHandler debugMode" is supposed to be used when you are
> developing with the browser right? When you don't use the browser you should
> find out bugs from the error message displayed on the browser?
> 

Mostly, yes. Sometimes I use the debug mode with the MiniDebugger in my
console.

> Question 5: When using the gst-browser, should I use the file out feature to
> keep my application on a VCS like Git or Bazaar? Or am I supposed to use a
> solution inside the browser to keep track of my code. I guess this is how it
> is done in Squeak, Dolphin etc?

I can't answer to this question, since I am myself waiting for a package
management with Git integration in VisualGST ;)

> Question 6: Again, when deploying my application would using the file out
> feature (and then preparing the .star package) be an elegant solution or
> when you develope an application on the browser it is supposed to be
> distributed via the image file?
> 
> Question 7: Does anybody use gst-browser to develop real applications yet?
> It seems to be giving errors for some basic things like creating a class :(

I use it sometimes to read code. I tried several times to develop using
it, and VisualGST is _really cool_, but some features are really missing
for me. (Sorry Gwen& Paolo)

On the other hand, I would really love to be able to use this IDE
sometimes instead of a text editor. Go VisualGST go!

Cheers,

-- 
Nicolas Petton

ObjectFusion S.A.R.L.
Applications web, consulting, design
http://www.objectfusion.fr

Attachment: signature.asc
Description: Ceci est une partie de message numériquement signée


reply via email to

[Prev in Thread] Current Thread [Next in Thread]