From 155bf78e3377910d29b2c912f58c0f496cb428e8 Mon Sep 17 00:00:00 2001 From: James Moger Date: Thu, 14 Apr 2011 19:44:47 -0400 Subject: Generate Keys class from gitblit.properties as part of build process. --- src/com/gitblit/utils/HtmlDiffFormatter.java | 2 +- src/com/gitblit/utils/JGitUtils.java | 4 ++-- src/com/gitblit/utils/Utils.java | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) (limited to 'src/com/gitblit/utils') diff --git a/src/com/gitblit/utils/HtmlDiffFormatter.java b/src/com/gitblit/utils/HtmlDiffFormatter.java index 08c0c219..a3e58c38 100644 --- a/src/com/gitblit/utils/HtmlDiffFormatter.java +++ b/src/com/gitblit/utils/HtmlDiffFormatter.java @@ -10,7 +10,7 @@ import org.eclipse.jgit.diff.DiffFormatter; import org.eclipse.jgit.diff.RawText; public class HtmlDiffFormatter extends DiffFormatter { - + private final OutputStream os; public HtmlDiffFormatter(OutputStream os) { diff --git a/src/com/gitblit/utils/JGitUtils.java b/src/com/gitblit/utils/JGitUtils.java index 69c46da4..fa313911 100644 --- a/src/com/gitblit/utils/JGitUtils.java +++ b/src/com/gitblit/utils/JGitUtils.java @@ -340,11 +340,11 @@ public class JGitUtils { } return null; } - + public static String getCommitPatch(Repository r, RevCommit commit) { return getCommitPatch(r, commit); } - + public static String getCommitPatch(Repository r, RevCommit commit, String path) { try { final RevWalk rw = new RevWalk(r); diff --git a/src/com/gitblit/utils/Utils.java b/src/com/gitblit/utils/Utils.java index c742fb62..6d0c6b3c 100644 --- a/src/com/gitblit/utils/Utils.java +++ b/src/com/gitblit/utils/Utils.java @@ -116,7 +116,7 @@ public class Utils { } return ago; } - + public static String leftPad(String input, int length, char pad) { if (input.length() < length) { StringBuilder sb = new StringBuilder(); @@ -128,19 +128,19 @@ public class Utils { } return input; } - + public static String rightPad(String input, int length, char pad) { if (input.length() < length) { StringBuilder sb = new StringBuilder(); sb.append(input); for (int i = 0, len = length - input.length(); i < len; i++) { sb.append(pad); - } + } return sb.toString(); } return input; } - + public static String escapeForHtml(String inStr, boolean changeSpace) { StringBuffer retStr = new StringBuffer(); int i = 0; -- cgit v1.2.3