You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@karaf.apache.org by ja...@apache.org on 2014/05/15 16:27:38 UTC

[2/3] git commit: KARAF-2982 - Command history is off by one

KARAF-2982 - Command history is off by one


Project: http://git-wip-us.apache.org/repos/asf/karaf/repo
Commit: http://git-wip-us.apache.org/repos/asf/karaf/commit/8eb59838
Tree: http://git-wip-us.apache.org/repos/asf/karaf/tree/8eb59838
Diff: http://git-wip-us.apache.org/repos/asf/karaf/diff/8eb59838

Branch: refs/heads/karaf-2.x
Commit: 8eb5983804e44e88c3758d2621532c5ce6ed540e
Parents: a27ef6c
Author: Jonathan Anstey <ja...@gmail.com>
Authored: Thu May 15 11:50:13 2014 -0230
Committer: Jonathan Anstey <ja...@gmail.com>
Committed: Thu May 15 11:50:13 2014 -0230

----------------------------------------------------------------------
 .../main/java/org/apache/karaf/shell/commands/HistoryAction.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/karaf/blob/8eb59838/shell/commands/src/main/java/org/apache/karaf/shell/commands/HistoryAction.java
----------------------------------------------------------------------
diff --git a/shell/commands/src/main/java/org/apache/karaf/shell/commands/HistoryAction.java b/shell/commands/src/main/java/org/apache/karaf/shell/commands/HistoryAction.java
index 3877572..af8b878 100644
--- a/shell/commands/src/main/java/org/apache/karaf/shell/commands/HistoryAction.java
+++ b/shell/commands/src/main/java/org/apache/karaf/shell/commands/HistoryAction.java
@@ -43,7 +43,7 @@ public class HistoryAction extends AbstractAction {
             System.out.println(
                     Ansi.ansi()
                         .a("  ")
-                        .a(Ansi.Attribute.INTENSITY_BOLD).render("%3d", element.index()).a(Ansi.Attribute.INTENSITY_BOLD_OFF)
+                        .a(Ansi.Attribute.INTENSITY_BOLD).render("%3d", element.index() + 1).a(Ansi.Attribute.INTENSITY_BOLD_OFF)
                         .a("  ")
                         .a(element.value())
                         .toString());