-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
use click for args, allow custom extensions
- Loading branch information
Showing
7 changed files
with
138 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +0,0 @@ | ||
from .gcal import gcal_ext | ||
from .todotxt import todotxt_ext | ||
|
||
EXTENSIONS = {"gcal": gcal_ext, "todotxt": todotxt_ext} | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
from typing import Type | ||
from .abstract import Extension | ||
|
||
EXTENSION_NAMES = {"gcal", "todotxt"} | ||
|
||
|
||
def get_extension(name: str) -> Type[Extension]: | ||
if name == "gcal": | ||
from .gcal import gcal_ext | ||
|
||
return gcal_ext | ||
elif name == "todotxt": | ||
from .todotxt import todotxt_ext | ||
|
||
return todotxt_ext | ||
else: | ||
raise ValueError(f"Unknown extension: {name}") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,6 +39,7 @@ exclude = | |
tests* | ||
include = | ||
calcurse_load | ||
calcurse_load.* | ||
gcal_index | ||
|
||
[options.extras_require] | ||
|