Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
topydo
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
topydo
Commits
bb9de101
Commit
bb9de101
authored
Oct 24, 2015
by
Jacek Sowiński
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add aliases into completion in prompt mode
parent
4d1a376b
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
topydo/cli/TopydoCompleter.py
topydo/cli/TopydoCompleter.py
+3
-1
No files found.
topydo/cli/TopydoCompleter.py
View file @
bb9de101
...
@@ -30,7 +30,9 @@ from topydo.lib.RelativeDate import relative_date_to_date
...
@@ -30,7 +30,9 @@ from topydo.lib.RelativeDate import relative_date_to_date
def
_subcommands
(
p_word_before_cursor
):
def
_subcommands
(
p_word_before_cursor
):
""" Generator for subcommand name completion. """
""" Generator for subcommand name completion. """
subcommands
=
[
sc
for
sc
in
sorted
(
_SUBCOMMAND_MAP
.
keys
())
if
sc_map
=
config
().
aliases
()
sc_map
.
update
(
_SUBCOMMAND_MAP
)
subcommands
=
[
sc
for
sc
in
sorted
(
sc_map
.
keys
())
if
sc
.
startswith
(
p_word_before_cursor
)]
sc
.
startswith
(
p_word_before_cursor
)]
for
command
in
subcommands
:
for
command
in
subcommands
:
yield
Completion
(
command
,
-
len
(
p_word_before_cursor
))
yield
Completion
(
command
,
-
len
(
p_word_before_cursor
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment