Annvix
Personal tools



/Documentation/execline

From Annvix

Writing run scripts with execline

Introduction to execline

Execline is a light weight non-interactive scripting language. It can be compiled with dietlibc and is very fast, small, and its obvious parser makes it more secure.

Here is some information: http://www.skarnet.org/software/execline/dieshdiedie.html

All of the execline package weighs in at about 748K across 39 programs. The main interpreter is only 25K in size.

The really nice thing is the running system memory compared to bash.

The six mingetty scripts, when using bash as the interpretter, leave a bash shell hanging in the background; each of these bash scripts utilizes 2040K of memory of which about 1008 is shared.

Execline will execute the mingetty executable and will not leave itself in the environment -- what this means is those /bin/sh programs will not exist anymore. This will save ((2040 - 1008) * 6) + 1008 = 7200K of memory on every Annvix distribution (numbers assume i586 arch -- will flux slightly on different archs and compiler settings) and six background processes.

Notes:

  • In execline basically all keywords are actually programs ... very little real lexical parsing going on.
  • If you read the docs for execline you will see that every command always ends in an optional another program.
  • So when you execute a execline script it is basically a daisy chain of each "statement" program executing.