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
2dab3dbb
Commit
2dab3dbb
authored
Aug 12, 2015
by
Bram Schoenmakers
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #49 from MinchinWeb/windows-cmd-2
Windows cmd 2 -- add color to output on Windows
parents
dfb8dd77
9650361b
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
59 additions
and
6 deletions
+59
-6
.gitignore
.gitignore
+20
-2
.travis.yml
.travis.yml
+5
-0
setup.py
setup.py
+28
-2
topydo/cli/UILoader.py
topydo/cli/UILoader.py
+4
-0
topydo/commands/ListCommand.py
topydo/commands/ListCommand.py
+1
-1
topydo/lib/PrettyPrinterFilter.py
topydo/lib/PrettyPrinterFilter.py
+1
-1
No files found.
.gitignore
View file @
2dab3dbb
*.pyc
*.sw?
build
dist
install
.coverage
# Distribution / packaging
.Python
env/
env*/
build/
develop-eggs/
dist/
eggs/
lib/
lib64/
parts/
sdist/
var/
*.egg-info/
.installed.cfg
*.egg
# Sublime Text
*.sublime-*
.travis.yml
View file @
2dab3dbb
sudo
:
false
# run on new infrastructure
language
:
python
python
:
-
"
2.7"
...
...
@@ -9,6 +10,10 @@ install:
-
"
pip
install
icalendar"
-
"
pip
install
pylint"
script
:
"
./run-tests.sh"
# Cache Dependencies
cache
:
directories
:
-
$HOME/travis/.cache/pip
notifications
:
webhooks
:
urls
:
...
...
setup.py
View file @
2dab3dbb
from
setuptools
import
setup
,
find_packages
import
os
import
re
import
codecs
import
sys
here
=
os
.
path
.
abspath
(
os
.
path
.
dirname
(
__file__
))
def
read
(
*
parts
):
# intentionally *not* adding an encoding option to open
return
codecs
.
open
(
os
.
path
.
join
(
here
,
*
parts
),
'r'
).
read
()
def
find_version
(
*
file_paths
):
version_file
=
read
(
*
file_paths
)
version_match
=
re
.
search
(
r"^VERSION = ['\"]([^'\"]*)['\"]"
,
version_file
,
re
.
M
)
if
version_match
:
return
version_match
.
group
(
1
)
raise
RuntimeError
(
"Unable to find version string."
)
conditional_dependencies
=
{
"colorama>=0.2.5"
:
"win32"
in
sys
.
platform
,
}
setup
(
name
=
"topydo"
,
packages
=
find_packages
(
exclude
=
[
"test"
]),
version
=
"0.5"
,
version
=
find_version
(
'topydo'
,
'lib'
,
'Version.py'
)
,
description
=
"A command-line todo list application using the todo.txt format."
,
author
=
"Bram Schoenmakers"
,
author_email
=
"me@bramschoenmakers.nl"
,
url
=
"https://github.com/bram85/topydo"
,
install_requires
=
[
'six >= 1.9.0'
,
],
]
+
[
p
for
p
,
cond
in
conditional_dependencies
.
items
()
if
cond
]
,
extras_require
=
{
'ical'
:
[
'icalendar'
],
'prompt-toolkit'
:
[
'prompt-toolkit >= 0.39'
],
...
...
topydo/cli/UILoader.py
View file @
2dab3dbb
...
...
@@ -20,6 +20,10 @@ import sys
import
getopt
from
topydo.cli.CLIApplicationBase
import
MAIN_OPTS
,
error
from
topydo.cli.CLI
import
CLIApplication
# enable color on windows CMD
if
"win32"
in
sys
.
platform
:
import
colorama
colorama
.
init
()
def
main
():
""" Main entry point of the CLI. """
...
...
topydo/commands/ListCommand.py
View file @
2dab3dbb
...
...
@@ -78,7 +78,7 @@ class ListCommand(ExpressionCommand):
Prints the todos in the right format.
Defaults to normal text output (with possible colors and other pretty
printing. If a format was specified on the commandline, this format is
printing
)
. If a format was specified on the commandline, this format is
sent to the output.
"""
...
...
topydo/lib/PrettyPrinterFilter.py
View file @
2dab3dbb
...
...
@@ -80,7 +80,7 @@ class PrettyPrinterColorFilter(PrettyPrinterFilter):
'
' + link_color + r'
\
2
\
3
' + color,
p_todo_str)
p_todo_str += NEUTRAL_COLOR
p_todo_str += NEUTRAL_COLOR
return p_todo_str
...
...
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