Skip to content

Commit

Permalink
Merge pull request #3651 from tessus/fix/branch-on-HEAD
Browse files Browse the repository at this point in the history
fix version when compiled at a specific commit
  • Loading branch information
dani-garcia authored Jul 5, 2023
2 parents a6cfddd + 2b32b6f commit 4826ddc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ fn version_from_git_info() -> Result<String, std::io::Error> {
// Combined version
if let Some(exact) = exact_tag {
Ok(exact)
} else if &branch != "main" && &branch != "master" {
} else if &branch != "main" && &branch != "master" && &branch != "HEAD" {
Ok(format!("{last_tag}-{rev_short} ({branch})"))
} else {
Ok(format!("{last_tag}-{rev_short}"))
Expand Down

0 comments on commit 4826ddc

Please sign in to comment.