Table of Contents

About

An Interactive shell 1) is created when bash is:

Management

Argument

When invoking an interactive shell, you can set the positional parameters with the -s option of bash. See Bash

Testing for Interactive mode

  • Testing for Interactive mode
if [[ $- == *i* ]]
then
    echo "Interactive"
fi

where