From f83fc2f0df43b4bd5bd55bfcbf6bb04003de52c3 Mon Sep 17 00:00:00 2001 From: Christopher Gallo Date: Fri, 9 Aug 2024 15:58:14 -0500 Subject: [PATCH 1/2] Updated snapcraft build to hopefully fix build errors. Fixed #2167 --- snap/snapcraft.yaml | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml index 42375ded7..4b78a2c9d 100644 --- a/snap/snapcraft.yaml +++ b/snap/snapcraft.yaml @@ -3,6 +3,7 @@ adopt-info: slcli summary: A CLI tool to interact with the SoftLayer API. description: | A command-line interface is also included and can be used to manage various SoftLayer products and services. + SLCLI documentation can be found here: https://softlayer-python.readthedocs.io/en/latest/ license: MIT @@ -10,14 +11,9 @@ base: core22 grade: stable confinement: strict -assumes: - - command-chain - apps: slcli: command: bin/slcli - command-chain: - - bin/homeishome-launch environment: LC_ALL: C.UTF-8 plugs: @@ -38,9 +34,4 @@ parts: - python3 stage-packages: - - python3 - - homeishome-launch: - plugin: nil - stage-snaps: - - homeishome-launch + - python3 From c4bded12ddc622983c3f368093a56cac97981a88 Mon Sep 17 00:00:00 2001 From: Christopher Gallo Date: Fri, 9 Aug 2024 16:01:46 -0500 Subject: [PATCH 2/2] Improved the formatting of hardware details page. Fixed #2153 --- SoftLayer/CLI/hardware/detail.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/SoftLayer/CLI/hardware/detail.py b/SoftLayer/CLI/hardware/detail.py index fe8661153..404a3235f 100644 --- a/SoftLayer/CLI/hardware/detail.py +++ b/SoftLayer/CLI/hardware/detail.py @@ -173,10 +173,13 @@ def _bw_table(bw_data): def _system_table(system_data): - table = formatting.Table(['Type', 'name']) + table = formatting.Table(['Type', 'Name']) + table.align['Type'] = 'r' + table.align['Name'] = 'l' + table.sortby = 'Type' for system in system_data: - table.add_row([utils.lookup(system, 'hardwareComponentModel', - 'hardwareGenericComponentModel', - 'hardwareComponentType', 'keyName'), - utils.lookup(system, 'hardwareComponentModel', 'longDescription')]) + c_type = utils.lookup(system, 'hardwareComponentModel', 'hardwareGenericComponentModel', + 'hardwareComponentType', 'keyName') + c_name = utils.lookup(system, 'hardwareComponentModel', 'longDescription') + table.add_row([c_type, c_name]) return table