Bash Internal variables $PPID


Example

The Process ID (pid) of the script or shell's parent, meaning the process than invoked the current script or shell.

~> $ echo $$
13016
~> $ echo $PPID
13015