Shell script flow charts

Visustin generates flow charts from Unix shell scripts.

Shell Name Current as of
sh Bourne Shell
csh, tcsh C Shell 6.18.01 (2012)
ksh KornShell 93 ksh93u+ (2012)
bash Bourne-Again SHell 4.2 (2011)

Earlier versions are supported as well.

If you are working with scripts in several different shells, please make sure you have selected the correct shell in Visustin. While the shells are similar to each other, there are small but important differences in the syntax.

Other, unlisted shells are supported up to the extent the syntax conforms to one of the above shells. Try either sh or bash mode to see how your scripts flowchart.

Supported statement types

Visustin supports the following generic statement types.

Statement typeExamples (actual keywords may differ)
Conditional statementsif..elif..else
Multiway decisioncase..esac
Iterationfor, foreach, select
Loopingwhile, until
Loop exit and continuebreak, continue
Jumpgoto (csh, tcsh)
Returnreturn
End scriptexit
Comments# comment, : comment
Functionsfunction
Boolean logic&& ||
Pipes| etc.
Here documents<<

The actual keywords differ a little based on the shell in question. Visustin supports all appropriate keywords. Visustin is aware of command grouping, subshells, pipelines, background execution, redirection and other typical shell constructs.

Most other commands are handled as regular statements.

Unsupported constructs

The following statement types are unsupported. Unsupported means you see the code in the graph as a normal statement, not as a branch or a jump.

©Aivosto OyVisustin Help