*CeJdZddlmZddlmZGddej Zy)znetplan get command line)NetplanConfigState)utilsc*eZdZfdZdZdZxZS) NetplanGetc*t|dddy)NgetzRGet a setting by specifying a nested key like "ethernets.eth0.addresses", or "all"T) command_id descriptionleaf)super__init__)self __class__s 2/usr/share/netplan/netplan_cli/cli/commands/get.pyr zNetplanGet.__init__s E%y"  $c|jjdtddd|jjddd |j|_|j |j y) Nkey?allzThe nested key in dotted format)typenargsdefaulthelpz --root-dir/z>Read configuration files from this root directory instead of /)rr)parser add_argumentstr command_getfunc parse_args run_command)rs rrunzNetplanGet.runsd   SUQr s   s&f ! h$$   rc^t|j|j}t|dy)N)end)rrroot_dirprint)r state_datas rrzNetplanGet.command_get(s '$--@  jb!r)__name__ __module__ __qualname__r r"r __classcell__)rs@rrrs$ "rrN)__doc__staterr$rNetplanCommandrrrr1s"$&"%%"r