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
f8d4a5af
Commit
f8d4a5af
authored
Jul 26, 2017
by
Bram Schoenmakers
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Deduplicate alphabet, but preserve order as it appears in the configuration
parent
1d333708
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
topydo/lib/Config.py
topydo/lib/Config.py
+4
-2
No files found.
topydo/lib/Config.py
View file @
f8d4a5af
...
@@ -20,6 +20,7 @@ import os
...
@@ -20,6 +20,7 @@ import os
import
re
import
re
import
shlex
import
shlex
from
collections
import
OrderedDict
from
itertools
import
accumulate
from
itertools
import
accumulate
from
string
import
ascii_lowercase
from
string
import
ascii_lowercase
...
@@ -478,8 +479,9 @@ class _Config:
...
@@ -478,8 +479,9 @@ class _Config:
def
identifier_alphabet
(
self
):
def
identifier_alphabet
(
self
):
alphabet
=
self
.
cp
.
get
(
'topydo'
,
'identifier_alphabet'
)
alphabet
=
self
.
cp
.
get
(
'topydo'
,
'identifier_alphabet'
)
# deduplicate characters alphabet
# deduplicate characters alphabet. Use a dictionary, but an ordered one
return
list
({
c
:
None
for
c
in
alphabet
}.
keys
())
# to keep determinism.
return
list
(
OrderedDict
([(
c
,
None
)
for
c
in
alphabet
]).
keys
())
def
config
(
p_path
=
None
,
p_overrides
=
None
):
def
config
(
p_path
=
None
,
p_overrides
=
None
):
"""
"""
...
...
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