Get the current abbreviated SHA of HEAD.
(git: GitClient)
| 93 | |
| 94 | /** Get the current abbreviated SHA of HEAD. */ |
| 95 | function getCurrentAbbrevSha(git: GitClient) { |
| 96 | try { |
| 97 | return git.run(['rev-parse', '--short', 'HEAD']).stdout.trim(); |
| 98 | } catch { |
| 99 | return ''; |
| 100 | } |
| 101 | } |
| 102 | |
| 103 | /** Get the current branch or revision of HEAD. */ |
| 104 | function getCurrentBranchOrRevision(git: GitClient) { |