Amiga.org

Amiga computer related discussion => Amiga Software Issues and Discussion => Topic started by: MiAmigo on December 26, 2004, 10:45:05 AM

Title: Best Scripting Language?
Post by: MiAmigo on December 26, 2004, 10:45:05 AM
It looks like I'm going to be reinstalling OS3.9 for quite a while, until I get it right. I really don't mind doing it, actually, it seems normal, when you cut your teeth on Windows. But, I am quickly getting tired of having to do manual installations of AmiCDFS. Not only do I prefer this CDROM file handling system to CacheCDFS, which comes with OS3.9, but I actually need to install it first, into WB3.1, before I can even reinstall OS3.9, sitting, as it does, on a CD drive. The installation instructions are simple enough, I just wish I could automate the process, and be done with it. I'm thinking a script is called for here. My question is: What is the best scripting tool available for the Amiga, that's already a part of the WB OS? :idea:
Title: Re: Best Scripting Language?
Post by: Piru on December 26, 2004, 11:55:16 AM
That'd be ARexx.
Title: Re: Best Scripting Language?
Post by: Thomas on December 26, 2004, 12:04:03 PM

The easiest would be to create an LhA archive with only the needed files in it which are already custimised.

E.g. install AmiCDFS once and then do something like this:

cd sys:
lha -x a work:cdfs l/amicdfs devs/dosdrivers/cd0(|.info)

Now, after you reinstalled 3.1, you only need to

lha x work:cdfs sys:

and everything is in place again.

Even better would be to LhA the complete system partition after successful installation. Then you can just unLhA the archive instead of doing a full installation again.

Bye,
Thomas
Title: Re: Best Scripting Language?
Post by: MiAmigo on December 26, 2004, 01:42:10 PM
Now that is a great idea (the lha stuff)! Actually, I like them both. Also, 'back in the day' I remember reading about the emergence of Arexx, and all the great things that could be done with it. But now, I'm afraid, after all these years, I've forgotten what little I knew about it. What's it all about, anyway?
Title: Re: Best Scripting Language?
Post by: carls on December 26, 2004, 04:19:00 PM
Quote
What's it all about, anyway?


ARexx might not be the world's best scripting language. In fact, it's quite dated by today's standards, even compared to Microsoft's VBScript. It's based on IBM's REXX, which was  used to automate stuff in their mainframe systems.

However, it has a lot of useful applications in the Amiga world. It was originally intended as a so called "IPC", InterProcess Communications language. This means that if two programs has an ARexx "port", you can most likely make them talk to each other using ARexx scripts.

An example of this is that you could write an ARexx script for your DTP program that loads a picture into ImageFX, where you can edit it, and then it's automatically reloaded in the DTP program. You can also do less obvious things such as trigger a backup of your hard drive from your favourite text editor. It all depends on what kind of ARexx support your programs have.

You can also write stand-alone programs in ARexx. Since it's a scripting language, and a rather simplistic one at that, you can't do any GUI or graphics stuff from it. However, a lot of expansion libraries are available, adding the possibility to, for example, create MUI applications and talk to SQL databases. Still, ARexx is a lot more powerful than just ordinary AmigaDOS scripts, thus enabling you to automate a lot of tedious tasks in a number of nifty ways.

If you're interested in ARexx, I recommend you to download ARexxGuide from Aminet.
Title: Re: Best Scripting Language?
Post by: MiAmigo on December 26, 2004, 09:46:25 PM
Well, just to be on the sate side, I did both (my first time!) and it worked without a hitch. Now, I want to study up on the syntax. More bathroom reading material!  :-P