Any terminal code to close all opened app?

image

this used to be my fav app in windows.

any terminal code to close them all?

Pkill will do that.

It uses lazy regex, so you can use partial application names.

 # pkill rome

Will terminate Chrome (and any other app containing “rome”, use wisely)

# pkill bash

Will terminate your current and any other terminal session / window.

Man page for pkill :

To terminate multiple processes by name, you can either :

 # pkill [app1] && pkill [app2]

or use killall

 # killall [app1] [app2]

Man page for killal :

What’s the scenario that you need to close all opened apps?
Some apps are running as service/daemon in the back end. Do you want to close them too?

I think GNOME’s task manager (System Monitor) does this under the Processes tab. Highlight all (ctrl + A) and kill should work I imagine.

after my days work i want to close all of these… i feel so lasy to close all these one by one. i just want to close the running app not the background app.

Log out and log in should work