From 34c711ea7024d87122d62a117c76b0215e3627aa Mon Sep 17 00:00:00 2001 From: Hiroaki Kobayashi Date: Mon, 15 Jan 2018 15:37:26 +0900 Subject: [PATCH] Align json indents This patch aligns indents for showing json data. Change-Id: I042f50a5bb06a0e84b142f9cd8f32ae26a4eb7a7 --- blazarclient/v1/shell_commands/hosts.py | 1 + blazarclient/v1/shell_commands/leases.py | 2 ++ 2 files changed, 3 insertions(+) diff --git a/blazarclient/v1/shell_commands/hosts.py b/blazarclient/v1/shell_commands/hosts.py index fb1ebf7..166eb3e 100644 --- a/blazarclient/v1/shell_commands/hosts.py +++ b/blazarclient/v1/shell_commands/hosts.py @@ -84,6 +84,7 @@ class CreateHost(command.CreateCommand): class UpdateHost(command.UpdateCommand): """Update attributes of a host.""" resource = 'host' + json_indent = 4 allow_names = False log = logging.getLogger(__name__ + '.UpdateHost') diff --git a/blazarclient/v1/shell_commands/leases.py b/blazarclient/v1/shell_commands/leases.py index 031dadc..35eff23 100644 --- a/blazarclient/v1/shell_commands/leases.py +++ b/blazarclient/v1/shell_commands/leases.py @@ -50,6 +50,7 @@ class ShowLease(command.ShowCommand): class CreateLease(command.CreateCommand): """Create a lease.""" resource = 'lease' + json_indent = 4 log = logging.getLogger(__name__ + '.CreateLease') default_start = datetime.datetime.utcnow() default_end = default_start + datetime.timedelta(days=1) @@ -277,6 +278,7 @@ class CreateLease(command.CreateCommand): class UpdateLease(command.UpdateCommand): """Update a lease.""" resource = 'lease' + json_indent = 4 log = logging.getLogger(__name__ + '.UpdateLease') def get_parser(self, prog_name):