summaryrefslogtreecommitdiff
path: root/uio.py
diff options
context:
space:
mode:
Diffstat (limited to 'uio.py')
-rw-r--r--uio.py31
1 files changed, 20 insertions, 11 deletions
diff --git a/uio.py b/uio.py
index 610ebca..c669a11 100644
--- a/uio.py
+++ b/uio.py
@@ -236,7 +236,7 @@ class PrintSystem:
self.print_usage(module, action)
self.print_line('')
# Action
- self.print_action(module, action)
+ self.print_action(action)
self.print_line('')
else:
# This means Action Done
@@ -300,26 +300,35 @@ class PrintSystem:
+ space + action_name + space + options)
def print_options(self):
+
self.print_line(highlight + space + 'Options:' + reset)
self.print_table([ \
[bold + '-v', bullet + space + 'Verbose Mode'], \
[bold + '-nc', bullet + space + 'No Colors'], \
- # [bold + '-profile', bullet + space + 'Profile Mode'], \
+ [bold + '-help', bullet + space + 'See this screen'], \
+ [bold + '-list', bullet + space + 'List Profiles'], \
[bold + '-version', bullet + space + 'Version Information']])
+ self.print_line('')
+ self.print_line(highlight + space + 'Usage Examples:' + reset)
+ self.print_table([ \
+ [bold + 'uprofile', bullet + space + 'Activates Folder Profile. Fallback to user profile.'], \
+ [bold + 'uprofile <profile>', bullet + space + 'See Details on <profile>']])
class ProfilePrintSystem(PrintSystem):
def print_ui(self, profile = None, profiles = None, args = None, \
- action = None):
-
+ action = None, help = False, list = False):
if profile == None:
- self.print_usage(profile = profile, action = action)
- self.print_line('')
- self.print_options()
- self.print_line('')
- self.print_profiles(profiles)
- self.print_line('')
+ if help or list:
+ self.print_usage(profile = profile, action = action)
+ self.print_line('')
+ if help:
+ self.print_options()
+ self.print_line('')
+ if list:
+ self.print_profiles(profiles)
+ self.print_line('')
elif profiles == None and action == None:
self.print_usage(profile = profile, action = action)
self.print_line('')
@@ -329,7 +338,7 @@ class ProfilePrintSystem(PrintSystem):
self.print_line('')
else:
for line in action.output:
- print line
+ print line
def print_profiles(self, profiles):
self.print_line(highlight + space + 'Profiles:' + reset)