examples: update python examples
Update the raw D-Bus python examples to use newer APIs where appropriate (and split the add-connection example into 1.0-only and 0.9-compatible versions). Update the gi-based python examples for the various API changes since they were last updated. Also add a comment to the ruby add-connection example pointing out that it's still using the old settings APIs.
This commit is contained in:
@@ -48,8 +48,8 @@ if __name__ == "__main__":
|
||||
sys.exit('Usage: %s <connection name or UUID> [new zone]' % sys.argv[0])
|
||||
|
||||
main_loop = GLib.MainLoop()
|
||||
settings = NM.RemoteSettings.new(None)
|
||||
connections = settings.list_connections()
|
||||
client = NM.Client.new(None)
|
||||
connections = client.get_connections()
|
||||
|
||||
con_name = sys.argv[1]
|
||||
if len(sys.argv) == 3:
|
||||
|
Reference in New Issue
Block a user