-
Notifications
You must be signed in to change notification settings - Fork 14
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
Add option for direct path to pci.ids #24
Conversation
This accommodates systems like OpenXT that store the PCI database in unconventional locations, or development systems that wish to use the database of a target system without reconfiguring the host environment. |
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.
Little naming suggestion, otherwise this is awesome, thank you @pearsonk!
In prep for the v0.6.0 release, once this is merged I'll update the README docs to explain the various options that allow discovering/overriding the PCIIDS file.
context.go
Outdated
@@ -25,6 +26,7 @@ func contextFromOptions(merged *WithOption) *context { | |||
cacheOnly: *merged.CacheOnly, | |||
cachePath: getCachePath(), | |||
disableNetworkFetch: *merged.DisableNetworkFetch, | |||
directPath: *merged.DirectPath, |
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.
How about we call this just Path
instead of DirectPath
? since it's an option, if Path
is set, it overrides any of the auto-discovery features.
Had an oops with a git rebase, will resubmit soon |
For systems placing the pci.ids database in a location other than <chroot>/usr/share/misc/pci.ids Signed-off-by: Kevin Pearson <kevin.pearson@ortmanconsulting.com>
Simplified DirectPath to Path, changed behavior to not enumerate cache or conventional locations when Path is set. |
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.
👍
For systems placing the pci.ids database in a location other than
/usr/share/misc/pci.ids
Signed-off-by: Kevin Pearson kevin.pearson@ortmanconsulting.com