1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-22 18:50:08 +03:00

L #-: Lint onevm CLI command

(cherry picked from commit b1be7955553c8afc002ed39d3b34ff897e2d7834)
This commit is contained in:
Tino Vázquez 2024-02-05 14:25:02 +01:00
parent aa22857d50
commit aa44b89c71
No known key found for this signature in database
GPG Key ID: 14201E424D02047E

View File

@ -1627,16 +1627,14 @@ CommandParser::CmdParser.new(ARGV) do
PCI_VENDOR,
PCI_DEVICE
] do
pci_attrs = [:pci, :pci_device, :pci_vendor, :pci_class].any? do |o|
!options[o].nil?
end
if options[:file]
template = File.read(options[:file])
elsif !(stdin = self.read_stdin).empty?
template = stdin
elsif !(stdin = OpenNebulaHelper.read_stdin).empty?
template = stdin
elsif pci_attrs
pcia = options[:pci]
pcid = options[:pci_device]