Skip to content
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

ci: return 7 symbols short git hash on branch build #18934

Merged
merged 1 commit into from
Nov 3, 2022

Conversation

cuyk
Copy link
Contributor

@cuyk cuyk commented Nov 3, 2022

What

For some reason git rev-parse --short HEAD started to return 8 symbols hash. It breaks updating OSS revision on cloud.

How

Return 7 symbols with git rev-parse --short=7 HEAD

@cuyk cuyk temporarily deployed to more-secrets November 3, 2022 19:09 Inactive
@cuyk cuyk force-pushed the vova/fix-update-oss-revision-in-cloud branch from bfbf754 to 318e1b2 Compare November 3, 2022 19:09
@cuyk cuyk marked this pull request as ready for review November 3, 2022 19:09
@cuyk cuyk temporarily deployed to more-secrets November 3, 2022 19:10 Inactive
@cuyk cuyk force-pushed the vova/fix-update-oss-revision-in-cloud branch from 318e1b2 to e816b47 Compare November 3, 2022 19:12
@cuyk cuyk temporarily deployed to more-secrets November 3, 2022 19:14 Inactive
@cuyk cuyk requested a review from supertopher November 3, 2022 19:28
Copy link
Contributor

@supertopher supertopher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

weird, ¯_(ツ)_/¯

I wonder if the underlying version of git changed

@cuyk cuyk merged commit afde9c6 into master Nov 3, 2022
@cuyk cuyk deleted the vova/fix-update-oss-revision-in-cloud branch November 3, 2022 19:50
@colesnodgrass
Copy link
Member

--short[=length]
Same as --verify but shortens the object name to a unique prefix with at least length characters. The minimum length is 4, the default is the effective value of the core.abbrev configuration variable

And core.abbrev is defined as

Set the length object names are abbreviated to. If unspecified or set to "auto", an appropriate value is computed based on the approximate number of packed objects in your repository, which hopefully is enough for abbreviated object names to stay unique for some time. If set to "no", no abbreviation is made and the object names are shown in their full length. The minimum length is 4.

My guess is that the number of packed objects in our repo has exceeded some value that caused it to increase the number of characters returned to help ensure uniqueness.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants