0

How to know the PID of the last open file (process) using the command line?

muru
  • 207,228
Maythux
  • 87,123

1 Answers1

1

The PID of the last process started from the terminal can be found in the ! variable:

gedit &
echo $!
Maythux
  • 87,123