Getting a list of currently running processes
ps -axc -o comm



-a displays processes from all users (or root)
-x includes processes that don't have a controlling terminal
-o comm outputs command paths or names
-c makes -o comm output names only


tell app "System Events" to name of application processes would list only processes launched from an application bundle.