[Top][All Lists]

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

Re: scripts one after the other

From: Quinn Fissler
Subject: Re: scripts one after the other
Date: Tue, 29 Mar 2016 09:56:27 +0100

On 26 March 2016 at 01:28, Val Krem <address@hidden> wrote:
> is it possible to combine the two scripts in one so that I can define the 
> varietals at one spot.  It would be less prone to error.

Yes - you can have a script with a "case" and hard link to another
name (you can symlink but they're not as efficient as hard links)


# set your variables here.

case "$0" in
      check your parameters for the first script...
      do stuff to create output | your_script_2.sh
      # some prog which reads input or read the input in bash
      while read Col1 Col2 Col3 RestOfLine
         do your stuff - reading a line at a time lets you pick off
columns if needed...
      echo We do not expect to be called $0

reply via email to

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