
Command Watch
Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net
Command Watch is a plasmoid which periodically runs a system command and displays its output. Think of a fortune or your uptime. The possibilities are endless.
Note: this Plasmoid is written for post-4.0.x Plasma versions.
12 years ago
Fix national characters, patch by Radek Novacek;
Make it compatible with KDE 4.2.
12 years ago
Fix national characters, patch by Radek Novacek;
Make it compatible with KDE 4.2.
cyberbat
8 years ago
Report
strungoutfan78
9 years ago
Report
frankqn1
11 years ago
Report
cmlr
11 years ago
Report
Kwilliam
12 years ago
1) Delete the line: find_package(Plasma REQUIRED)
2) Replace ${PLASMA_LIBS} with ${KDE4_PLASMA_LIBS}
Report
bram85
12 years ago
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -3,7 +3,12 @@ project(plasma-flickrop)
# Find the required Libaries
find_package(KDE4 REQUIRED)
include(KDE4Defaults)
-find_package(Plasma REQUIRED)
+
+if ( ${KDE_VERSION} VERSION_LESS "4.1.90" )
+ find_package(Plasma REQUIRED)
+else ( ${KDE_VERSION} VERSION_LESS "4.1.90" )
+ set( PLASMA_LIBS ${KDE4_PLASMA_LIBS} )
+endif ( ${KDE_VERSION} VERSION_LESS "4.1.90" )
add_definitions (${QT_DEFINITIONS} ${KDE4_DEFINITIONS})
include_directories(
Report
patkoscsaba
12 years ago
The if statement looks buggy. After I removed it, it compiles ok.
This is the error:
-- Found automoc4: /usr/bin/automoc4
CMake Error at CMakeLists.txt:6 (if):
if had incorrect arguments: ${KDE_VERSION} VERSION_LESS "4.1.90" (Unknown
arguments specified).
-- Found Plasma: /usr/lib/libplasma.so
CMake Error at CMakeLists.txt:8 (else):
else An ELSE command was found outside of a proper IF ENDIF structure. Or
its arguments did not match the opening IF command.
CMake Error at CMakeLists.txt:10 (endif):
endif An ENDIF command was found outside of a proper IF ENDIF structure.
Or its arguments did not match the opening IF command.
-- Configuring done
Report
bram85
12 years ago
What is your CMake version? Mine is version 2.6-patch 2.
Report
Bolde
12 years ago
Extraallt prints the output from specified commands to a text file. Per default it prints the output from hddtemp, lm-sensors and /proc/cpuinfo. Just use it with Command watch and "cat textfile" and set it to update every 3 second.
http://www.cli-apps.org/content/show.php?content=96157
Command watch needs the UTF-patch to print degree symbols, described in the post above by user radnnn
Awk gurus can probably make it print anything.
Report
Kwilliam
12 years ago
build-essential, cmake, kdelibs5-dev, libplasma-dev
Tip: I suggest installing the "apt-file" program. When cmake complains that it can't find the file such-and-such, use "apt-file search such-and-such" to find the package with the needed file.
Report
radnnn
12 years ago
replace line 216:
Quote:m_output = m_proc.readAllStandardOutput();
with
Quote:m_output = QString::fromUtf8(m_proc.readAllStandardOutput());
It should work for at least UTF-8 locales...
Report
devel0per
12 years ago
Report
zaardvark
12 years ago
Thanks again.
Report
Kwilliam
12 years ago
Refresh every: 5 seconds
Font: Monospace 9
Command: Quote:top -b | head -17 | tail -11 | awk '$9!=0 {printf("%5s %4s %s\n",$1,$9,$12)}'
top -b | head -17 | tail -11 gets the top 10 processes using the most CPU. The awk command filters out processes with 0% CPU, and cuts down the displayed information to just the process name, PID, and %CPU.
Report
devel0per
12 years ago
top -n 1 -b | head -17 | tail -11 | awk '$9!=0 {printf("%5s %4s %5s %s\n",$1,$9,$6,$12)}'
will be a bit better.
* -n option for top is added;
* memory usage information is added;
It's faster and for me - previous variant simply doesn't work, because it's hold output (symptom - screen is not updated).
Report
Kwilliam
12 years ago
Report
Kwilliam
12 years ago
Refresh every: 5 seconds
Font: Monospace 9
Command: Quote:top -b | head -17 | tail -11 | awk '$9!=0 {printf("%5s %4s %s\n",$1,$9,$12)}'
top -b | head -17 | tail -11 gets the top 10 processes using the most CPU. The awk command filters out processes with 0% CPU, and cuts down the displayed information to just the process name, PID, and %CPU.
Report
warezmen
12 years ago
i add you plasmoid on my debian repo
deb http://www.amarok2deb.co.cc/debian/ unstable main
Report