Update cli menu view

This commit is contained in:
Dimitris Zlatanidis 2022-06-21 09:35:35 +03:00
parent 9ca9d28633
commit fe44576d96
4 changed files with 24 additions and 17 deletions

View file

@ -43,9 +43,10 @@ Usage
USAGE: slpkg [OPTIONS] <packages>
DESCRIPTION:
Packaging tool that interacts with the SBo repository.
OPTIONS:
COMMANDS:
update Update the package lists.
build <packages> Build only the packages.
install <packages> Build and install the packages.
@ -53,6 +54,7 @@ Usage
search <packages> Search packages by name.
clean-logs Purge logs of dependencies.
OPTIONS:
--yes Answer Yes to all questions.
--jobs Set it for multicore systems.
--resolve-off Turns off dependency resolving.

View file

@ -10,7 +10,7 @@ slpkg [-h|-v] [update] [build] [install] [remove] [search] [clean-logs] --yes --
Slpkg is a software package manager that installs, updates, and removes packages on Slackware based systems. It automatically computes dependencies and figures out what things should occur to install packages. Slpkg makes it easier to maintain groups of machines without having to manually update.
.P
Slpkg works in accordance with the standards of the organization SlackBuilds.org to build packages. Also uses the Slackware Linux instructions for installation, upgrading or removing packages.
.SH OPTIONS
.SH COMMANDS
.P
update
.RS
@ -41,6 +41,7 @@ clean-logs
.RS
Purge logs of dependencies.
.RE
.SH OPTIONS
.P
--yes
.RS

View file

@ -102,6 +102,7 @@ class Configs:
if cls.colors in ['on', 'ON']:
color = {
'BOLD': '\033[1m',
'RED': '\x1b[91m',
'GREEN': '\x1b[32m',
'YELLOW': '\x1b[93m',

View file

@ -9,20 +9,23 @@ def usage(status: int):
colors = Configs.colour
color = colors()
BOLD = color['BOLD']
RED = color['RED']
CYAN = color['CYAN']
YELLOW = color['YELLOW']
ENDC = color['ENDC']
args = [f'USAGE: {Configs.prog_name} [{CYAN}OPTIONS{ENDC}] <packages>\n',
args = [f'{BOLD}USAGE:{ENDC} {Configs.prog_name} [{CYAN}OPTIONS{ENDC}] <packages>\n',
f'{BOLD}DESCRIPTION:{ENDC}',
' Packaging tool that interacts with the SBo repository.\n',
'OPTIONS:',
f'{BOLD}COMMANDS:{ENDC}',
f' {RED}update{ENDC} Update the package lists.',
f' {CYAN}build{ENDC} <packages> Build only the packages.',
f' {CYAN}install{ENDC} <packages> Build and install the packages.',
f' {CYAN}remove{ENDC} <packages> Remove installed packages.',
f' {CYAN}search{ENDC} <packages> Search packages by name.',
f' {CYAN}clean-logs{ENDC} Purge logs of dependencies.\n',
f'{BOLD}OPTIONS:{ENDC}',
f' {YELLOW}--yes{ENDC} Answer Yes to all questions.',
f' {YELLOW}--jobs{ENDC} Set it for multicore systems.',
f' {YELLOW}--resolve-off{ENDC} Turns off dependency resolving.',