aabouzaid / netbox-as-ansible-inventory

Ansible dynamic inventory script for Netbox.
GNU General Public License v3.0
174 stars 54 forks source link

Added option to use `slug` instead of `name` as a key in netbox `dict` #6

Open bdlamprecht opened 7 years ago

bdlamprecht commented 7 years ago

This is my first Git "Fork / Pull" request so I apologize if I didn't follow protocol.

I implemented an option to to use slug as the key in netbox as I requested in issue https://github.com/AAbouZaid/netbox-as-ansible-inventory/issues/4.

Also, I thought it would be nice to add the --version to argparse to keep a handle on the progression of this code.

Feel free to change the variable names and comments I used in the netbox.yml file or even the entire method. I'm not a developer by trade, so again, sorry in advance.

aabouzaid commented 7 years ago

Cool, could you please check the failed tests?