Skip to content

Loading…

53c9a0f6216 breaks when current commit == tag #20

Closed
hyperthunk opened this Issue · 2 comments

2 participants

@hyperthunk

This code breaks when you've just made a tag and the git command returns the tag-name instead of the commit sha!

get_git_branch() ->
    Git = os:cmd("git describe --always --all"),   %% returns v0.7.8 when that's the current commit!
    case string:tokens(Git, " \n/") of
        [_, Branch] -> Branch;
        Other       -> erlang:error({cannot_get_git_branch, Other})
    end.
@uwiger uwiger added a commit that referenced this issue
@uwiger uwiger Issue #20: default branch to master 35f8296
@uwiger

Thanks. I just pushed an update to master, where the fallback for get_git_branch() becomes "master".

@uwiger

closing - reopen issue if still a problem.

@uwiger uwiger closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.