aboutsummaryrefslogtreecommitdiff
path: root/examples/top.sh
diff options
context:
space:
mode:
authorDeterminant <ted.sybil@gmail.com>2014-12-29 00:34:16 +0800
committerDeterminant <ted.sybil@gmail.com>2014-12-29 00:34:16 +0800
commit4c7c9dcdfd05a2d9648756c0da5c68588929ba5d (patch)
tree2c1681ad60e1469b4dda7a2ab6a0d03637dbde1e /examples/top.sh
parent5dc3a3b043a990fc58a4ead74c2c5c92e910727d (diff)
restructured the project
Diffstat (limited to 'examples/top.sh')
-rwxr-xr-xexamples/top.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/examples/top.sh b/examples/top.sh
new file mode 100755
index 0000000..55288b8
--- /dev/null
+++ b/examples/top.sh
@@ -0,0 +1,8 @@
+#!/bin/bash
+export JMNAME='TOP'
+export JTYPE='listgraph'
+function trigger {
+ top -bn1 -S | tail -n +8 | head -n 10 | awk '{ print $1, $2}' | $CLIENT --alter "$JID"
+}
+export -f trigger
+./monitor_daemon.sh