SDB: Added '--no-pager' and '-l' options to journalctl 16/27716/1
authorAlice Liu <alice.liu@intel.com>
Thu, 18 Sep 2014 05:14:31 +0000 (13:14 +0800)
committerAlice Liu <alice.liu@intel.com>
Thu, 18 Sep 2014 05:14:31 +0000 (13:14 +0800)
journalctl uses a pager for stdout. After "sdb shell",
the pager will not display the text beyond 80 characters.
So added '--no-pager' and '-l' options to journalctl to
make "sdb dlog" show the text beyond 80 characters by
default.

Change-Id: I3f7a630e750e0532f5c1a504d95a6b99a386b0d8
Signed-off-by: Alice Liu <alice.liu@intel.com>
src/command_function.c

index 884f4c994d170ada88ce4cca1b1ee67f1071f587..8660714f21142a97ad0e56ab0d5712f9c954f153 100644 (file)
@@ -499,7 +499,7 @@ int dlog(int argc, char ** argv) {
     if (verify_journalctl_exist() < 0) {
         snprintf(full_cmd, sizeof full_cmd, "shell:/usr/bin/dlogutil");
     } else {
-        snprintf(full_cmd, sizeof full_cmd, "shell:/usr/bin/journalctl");
+        snprintf(full_cmd, sizeof full_cmd, "shell:/usr/bin/journalctl --no-pager -l");
     }
 
     int i;