As I was going through the code, this struck me as odd.
In this snippet, we refer to @machine_name if config[:limit] is false
# By default we limit by the current machine,
if config[:limit]
options << "--limit=#{as_list_argument(config[:limit])}"
else
options << "--limit=#{@machine_name}"
end
@machine_name is initialized in prepare_inventory if config[:generate_inv]
so it seems like there may be an issue if config[:generate_inv] is false and config[:limit] is also false since the code would refer to @machine_name but it wouldn't have been initialized?
As I was going through the code, this struck me as odd.
In this snippet, we refer to
@machine_name
ifconfig[:limit]
is false@machine_name
is initialized inprepare_inventory if config[:generate_inv]
so it seems like there may be an issue if
config[:generate_inv]
is false andconfig[:limit]
is also false since the code would refer to@machine_name
but it wouldn't have been initialized?