axrun: run commands with the same partial parameters The purpose of the utility is that we can run several commands from one command line, where we can get the commands use the same prameters (without storing these common parameters in evironment variables). Usage: axrun {set var=value} cmd1 {params} + cmd2 {params} +cin cmd3 {params} ... The 'set' parameter is used to specifiy variables that are used in the subsequent commands, in the form of '$(VAR)'. Here we can use the environment variables (like '$(PATH)') and other, axrun-specific variables: - YEAR - MON - DAY - HOUR - MIN - SEC These variables contains the value of starting time of the command line. The subsequent commands are separated either by '+' or '+cin'. The second one indicates that the following command receives the input of the axrun (its standard input). We can use the varibales (that were defined with 'set') in these commands. Examples: axrun set APPLE=apple ls '$(APPLE)' + cp '$(APPLE) $(APPLE).bak' -> the 'apple' directory will be listed and copied into a temp dir afind '*.txt' | axrun set 'NAME=$(YEAR)_$(MON)_$(DAY).zip' +cin azip -stdin -o '$(NAME)' + cp '$(NAME)' bak + scp '$(NAME)' user1@10.20.30.50:/home/archiv -> find the text files, zip them into a file named after the current time, and copy the zip into the archive directory and an other archive directory a remote machine (the zip out and the copy in file names are the same) Note the apostrophes around the variable names in the examples: they are necessary to avoid the shell processing of the variable names (they don't exist in the shell environment). These are necessary on Unices, the Windows command line doesn't need them.