summaryrefslogtreecommitdiff
path: root/bin/rbot
diff options
context:
space:
mode:
authorGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2007-08-27 01:41:31 +0000
committerGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2007-08-27 01:41:31 +0000
commit6cc39542e60e4673328af88d37e67a3bd38dbb93 (patch)
tree990d1ea4ce780143af200035e2f48379b6f2ea23 /bin/rbot
parent36b1426d7235344b4b33567de29b767ae2882276 (diff)
Show the git version differently
Diffstat (limited to 'bin/rbot')
-rwxr-xr-xbin/rbot8
1 files changed, 4 insertions, 4 deletions
diff --git a/bin/rbot b/bin/rbot
index 94634458..1a879380 100755
--- a/bin/rbot
+++ b/bin/rbot
@@ -48,13 +48,13 @@ if $version =~ /svn/
git_out = `git status`
git_out.match(/^# On branch (.*)\n/)
- branch = $1
+ branch = $1.dup || "unknown"
changed = git_out.match(/^# Change(.*)\n/)
- rev = " @ #{`git rev-parse HEAD`[0..6]}"
+ rev = "revision "
+ rev << `git rev-parse HEAD`[0..5]
rev << ", local changes" if changed
- $version << "-#{branch}" unless branch.empty?
- $version << rev
+ $version << " (#{branch} branch, #{rev})"
else
up = File.dirname(__FILE__) + "/.."
rev = " (unknown revision)"