From 5a70ef6befc3b74e21033f208be86d5aa0255d98 Mon Sep 17 00:00:00 2001 From: Giuseppe Bilotta Date: Thu, 22 Jan 2009 23:29:50 +0100 Subject: launch_here: add commit subject rather than svn id to revision There are no git-svn-ids in our repository, so don't look for them. Instead, put the last commit subject next to the revision to ease identification of the commit. --- launch_here.rb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'launch_here.rb') diff --git a/launch_here.rb b/launch_here.rb index 6f9de4bf..e1e4a011 100755 --- a/launch_here.rb +++ b/launch_here.rb @@ -22,10 +22,12 @@ begin branch = $1.dup || "unknown" changed = git_out.match(/^# Change(.*)\n/) rev = "revision " - git_out = `git log -1 --pretty=format:"%h%n%b%n%ct"`.split("\n") + git_out = `git log -1 --pretty=format:"%h%n%s%n%ct"`.split("\n") rev << git_out.first + subject = git_out[1].strip + subject[77,subject.length] = "..." if subject.length > 80 + rev << " [#{subject}]" unless subject.empty? $version_timestamp = git_out.last.to_i - rev << "(svn #{$1})" if git_out[1].match(/^git-svn-id: \S+@(\d+)/) rev << ", local changes" if changed else # older gits git_out = `git branch` -- cgit v1.2.3