summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohn Estabrook <jestabro@vyos.io>2022-10-27 12:24:44 -0500
committerJohn Estabrook <jestabro@vyos.io>2022-10-28 08:00:56 -0500
commit0e63712195465c9bf0bf55c369b86961d54dfaac (patch)
tree0079fa2ede8e2dafb9486d4a6272dddb7fa81655 /src
parentea8d4ae325059681460f6c74751cfe8ebb2931bc (diff)
downloadvyos-1x-0e63712195465c9bf0bf55c369b86961d54dfaac.tar.gz
vyos-1x-0e63712195465c9bf0bf55c369b86961d54dfaac.zip
T4291: consolidate component version string read/write functions
Diffstat (limited to 'src')
-rwxr-xr-xsrc/helpers/system-versions-foot.py21
1 files changed, 5 insertions, 16 deletions
diff --git a/src/helpers/system-versions-foot.py b/src/helpers/system-versions-foot.py
index 2aa687221..9614f0d28 100755
--- a/src/helpers/system-versions-foot.py
+++ b/src/helpers/system-versions-foot.py
@@ -1,6 +1,6 @@
#!/usr/bin/python3
-# Copyright 2019 VyOS maintainers and contributors <maintainers@vyos.io>
+# Copyright 2019, 2022 VyOS maintainers and contributors <maintainers@vyos.io>
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
@@ -16,24 +16,13 @@
# along with this library. If not, see <http://www.gnu.org/licenses/>.
import sys
-import vyos.formatversions as formatversions
-import vyos.systemversions as systemversions
import vyos.defaults
-import vyos.version
-
-sys_versions = systemversions.get_system_component_version()
-
-component_string = formatversions.format_versions_string(sys_versions)
-
-os_version_string = vyos.version.get_version()
+from vyos.component_version import write_system_footer
sys.stdout.write("\n\n")
if vyos.defaults.cfg_vintage == 'vyos':
- formatversions.write_vyos_versions_foot(None, component_string,
- os_version_string)
+ write_system_footer(None, vintage='vyos')
elif vyos.defaults.cfg_vintage == 'vyatta':
- formatversions.write_vyatta_versions_foot(None, component_string,
- os_version_string)
+ write_system_footer(None, vintage='vyatta')
else:
- formatversions.write_vyatta_versions_foot(None, component_string,
- os_version_string)
+ write_system_footer(None, vintage='vyos')