Update source for NVML header downloads to NVIDIA owned repo#124
Update source for NVML header downloads to NVIDIA owned repo#124klueska merged 1 commit intoNVIDIA:mainfrom
Conversation
c0516c9 to
99b70d3
Compare
Makefile
Outdated
| wget -qO - https://api.anaconda.org/package/nvidia/cuda-nvml-dev/files | \ | ||
| $(JQ) '.[] | select(.attrs.subdir=="linux-64") | .version + "@" + .upload_time[:19] + "@" + .full_name' | \ | ||
| update-nvml-h: NVML_DEV_HEADERS_INFO := $(shell \ | ||
| wget -qO - https://gitlab.com/api/v4/projects/nvidia%2Fheaders%2Fcuda-individual%2Fnvml_dev/repository/tags | \ |
There was a problem hiding this comment.
How about using git clone rather than querying the RESTful API? Since we are querying a git repo.
$ git clone https://gitlab.com/nvidia/headers/cuda-individual/nvml_dev.git nvml-dev
$ cd nvml-dev
$ git tag --list 'v*' --sort='-version:refname' --format='%(refname:short)%09%(*authordate:format:%Y-%m-%d-%H:%M:%S)'
v12.5.39 2024-05-15-22:26:21
v12.4.127 2024-03-28-23:49:40
v12.4.99 2024-02-29-05:54:15
v12.3.101 2023-11-09-11:05:04
v12.3.52 2023-10-16-04:09:26
v12.2.140 2023-08-23-07:12:43
v12.2.128 2023-07-27-08:52:32
v12.2.81 2023-06-26-10:09:29
v12.1.105 2023-04-17-17:34:53
v12.1.55 2023-02-23-09:20:23
v12.0.140 2023-01-28-19:30:42
v12.0.76 2022-12-03-11:07:09
v11.8.86 2022-09-29-20:24:19
v11.7.91 2022-07-29-12:29:29
v11.7.50 2022-05-04-18:22:18
v11.6.55 2022-01-11-16:52:51
v11.5.50 2022-01-10-17:04:04
v11.4.120 2022-01-28-00:02:05
$ git checkout v12.5.39
Note: switching to 'v12.5.39'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.
If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:
git switch -c <new-branch-name>
Or undo this operation with:
git switch -
Turn off this advice by setting config variable advice.detachedHead to false
HEAD is now at 878f50f CUDA 12.5.0 nvML_DEV 12.5.39
$ cp -f nvml.h ../gen/nvml/nvml.h|
I don't want to clone the whole repo just to pull one file out of it and then delete the repo. What advantage would cloning serve? |
The repo only contains three files:
|
Signed-off-by: Kevin Klues <kklues@nvidia.com>
99b70d3 to
8c2b25e
Compare
|
I've updated my version to at least include all of the tags that it should (i.e. 18). @elezar what are your thoughts on using the REST API vs. cloning the whole repo? |
It's not about the size of the repo, but about the cleanup that needs to get done if something goes wrong. I do not want to be including this as a submodule as we don't actually depend on it for anything other than getting the latest NVML header (when appropriate). |
elezar
left a comment
There was a problem hiding this comment.
Let's use thie REST API for this change and consider switching as a follow-up.
I suppose toding a shallow-clone and then fetching the tags is an option. We can also clone to /tmp so as to not have long-lived changes.
An example of running this now looks like: