ichor.cli.completers package
Submodules
ichor.cli.completers.tab_completer module
Implements Tab completion for ICHOR’s menus. Tab completion is handy when providing files or browsing between ICHOR menus.
- class DoNothingCompleter
Bases:
TabCompleterThis completer does not do anything, but fixes issues where PathCompleter modifies how the tab button works.
- completer(text, state)
Needs to be implemented by any class inheriting from TabCompleter. This method will define what kinds of things are shown with Tab completion.
- Parameters:
text – Text that has been typed into the prompt
state – An integer value that is used by the readline package to return possible word completions. See readline.set_completer in docs.
- remove_completer() None
Remove the completer to prevent word completion in a menu.
- setup_completer(pattern='\t') None
If readline package is present, then we can use tab completion. :param pattern: Which set of characters to use as delimiter. Default is ` ` which is a Tab
- class PathCompleter
Bases:
TabCompleterUsed to show the paths to files when the user pressed Tab.
- completer(text, state)
Needs to be implemented by any class inheriting from TabCompleter. This method will define what kinds of things are shown with Tab completion.
- Parameters:
text – Text that has been typed into the prompt
state – An integer value that is used by the readline package to return possible word completions. See readline.set_completer in docs.
- class TabCompleter
Bases:
ABCAbstract method for any kind of auto completion in the user input prompt when pressing Tab.
- abstract completer(text, state)
Needs to be implemented by any class inheriting from TabCompleter. This method will define what kinds of things are shown with Tab completion.
- Parameters:
text – Text that has been typed into the prompt
state – An integer value that is used by the readline package to return possible word completions. See readline.set_completer in docs.
- remove_completer() None
Remove the completer to prevent word completion in a menu.
- setup_completer(pattern='\t') None
If readline package is present, then we can use tab completion. :param pattern: Which set of characters to use as delimiter. Default is ` ` which is a Tab
Module contents
- class DoNothingCompleter
Bases:
TabCompleterThis completer does not do anything, but fixes issues where PathCompleter modifies how the tab button works.
- completer(text, state)
Needs to be implemented by any class inheriting from TabCompleter. This method will define what kinds of things are shown with Tab completion.
- Parameters:
text – Text that has been typed into the prompt
state – An integer value that is used by the readline package to return possible word completions. See readline.set_completer in docs.
- remove_completer() None
Remove the completer to prevent word completion in a menu.
- setup_completer(pattern='\t') None
If readline package is present, then we can use tab completion. :param pattern: Which set of characters to use as delimiter. Default is ` ` which is a Tab
- class PathCompleter
Bases:
TabCompleterUsed to show the paths to files when the user pressed Tab.
- completer(text, state)
Needs to be implemented by any class inheriting from TabCompleter. This method will define what kinds of things are shown with Tab completion.
- Parameters:
text – Text that has been typed into the prompt
state – An integer value that is used by the readline package to return possible word completions. See readline.set_completer in docs.