-
-
Notifications
You must be signed in to change notification settings - Fork 607
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Conky takes process names from /proc/<pid>/stat and it's limited to 16 chars in kernel. That obviously makes top_name_width option to work only for decreasing name length. To obtain longer names we parse /proc/<pid>/cmdline. Not every process has cmdline, so we take both process names and choose one we want to use. Like this: - Get process name from /proc/<pid>/stat - Get process cmdline from /proc/<pid>/cmdline - Transform cmdline to a bit simpler form(i.e. "/usr/bin/python /usr/bin/terminator" to "python /usr/bin/terminator"), keeping the arguments(might be changed easily) - Choose the one that is longer and use it
- Loading branch information
alcazoid
committed
Apr 9, 2013
1 parent
459dd41
commit 749083a
Showing
1 changed file
with
56 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters