-
-
Notifications
You must be signed in to change notification settings - Fork 564
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
installing gitui releases from source results in a "nightly" version string by default #2254
Comments
please checkout #2187 and the newly introduced the |
This would work. However, I don't want to introduce another manual step into the process of updating our packages. I'd have to look up the commit hash that corresponds to the tagged release for every new release, and I can't automate that. I could set If the git commit hash cannot be determined, maybe it would be better to just exclude it from the format string? i.e. something like if let Some(hash) = commit_hash {
format!("{} {} ({})", gitui_version, source_date, hash)
} else {
format!("{} {}", gitui_version, source_date)
}
Yeah, I'm not sure how to fix this either. Maybe set the version string to "nightly" only if the git commit hash can be determined and |
Running
cargo install gitui
as documented here:https:/extrawurst/gitui?tab=readme-ov-file#cargo-install
Results in
gitui --version
returning:gitui nightly 2024-06-02 ()
(replace2024-06-02
with the current date)I'm also having trouble making this work sensibly for the Fedora Linux package for gitui.
I can easily set
GITUI_RELEASE=1
, but then theget_git_hash()
function from build.rs will fail hard (with anstd::io::Error: No such file or directory
) ifgit
is not installed in the build environment. And ifgit
is available, it will either return""
(in the case where the git command fails with no output on stdout) or random garbage if there is an unrelated git repository in any of the parent directories.Would you accept a PR that adapted build.rs to work better in more cases, for example, when
git
is not available?The text was updated successfully, but these errors were encountered: