Module: CommitMsgUrlShortener::Git

Extended by:
Git
Included in:
Git
Defined in:
lib/commit-msg-url-shortener/git.rb

Instance Method Summary collapse

Instance Method Details

#toplevelObject



4
5
6
7
8
# File 'lib/commit-msg-url-shortener/git.rb', line 4

def toplevel
  git_path = %x[git rev-parse --show-toplevel] rescue ''
  git_path.strip!
  git_path if File.directory? git_path 
end