-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
[misc] Use configured headers to track version and commit hash #3349
Conversation
✔️ Deploy Preview for jovial-fermat-aa59dc canceled. 🔨 Explore the source changes: fa9c9ea 🔍 Inspect the deploy log: https://app.netlify.com/sites/jovial-fermat-aa59dc/deploys/6180f8125b0e420007357020 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yesss! Nice work!
"#define TI_VERSION_PATCH \"${TI_VERSION_PATCH}\"\n" | ||
"#define TI_CUDAVERSION \"${CUDA_VERSION}\"\n" | ||
) | ||
configure_file(taichi/common/version.h.in version.h) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we somehow still keep these headers in taichi/common folder? ;)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure. Which one do you think is better?
- add
.in
suffix to distinguish the files before and after processing - or just process them in place
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sjwsl let's keep the .in
suffix so that we know what happened there :D Thanks a lot!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it. But I accidentally deleted my local branch so can't update this PR now... Could you help merge this first and then I will give another PR for this. Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
…i-dev#3349) * [Build] Use configured header file to track version and commit hash * fix
Instead of generating headers manually, use a more standard way to track the version and commit hash. It is easier to maintain and understand now.
Test on my local machine by building different versions.
This is the prerequisite for #3354.