Scripting the rebourne SHELL

Here is a reference to BASH ( the "Bourne Again SHell" ). What brought it up is an article on $IFS and now I have satisfied my curiosity.

echo bash is where $BASH
echo env $BASH_ENV
echo subshell $BASH_SUBSHELL
for n in 0 1 2 3 4 5
do
 echo "$n =${BASH_VERSIONINFO[$n]}"
done
echo bash version $BASH_VERSION
echo shell $SHELL
echo "IFS --- $IFS ..."
echo dirstack  $DIRSTACK

That didn't work for Version Info and I wondered why. It is very strange how the mind does "automatic tab completion" and then conceals the fact that it did.

echo bash is where $BASH
echo env $BASH_ENV
echo subshell $BASH_SUBSHELL
echo mach type $MACHTYPE
echo "0 = ${BASH_VERSINFO[0]}"
for n in 0 1 2 3 4 5
do
 echo "$n = ${BASH_VERSINFO[$n]}"
done
echo bash version $BASH_VERSION
echo shell $SHELL
echo "IFS --- $IFS ..."
echo dirstack  $DIRSTACK

This works and it should be obvious what the problem was.

0 comments:

Contributors

Automated Intelligence

Automated Intelligence
Auftrag der unendlichen LOL katzen