add indexing category
This commit is contained in:
parent
e585fbb4a8
commit
358308c993
4 changed files with 7 additions and 3 deletions
|
@ -32,7 +32,8 @@ optional arguments:
|
||||||
"domain" or "app". Defaults to "file".
|
"domain" or "app". Defaults to "file".
|
||||||
--category CATEGORY Category of this heartbeat activity. Can be "coding",
|
--category CATEGORY Category of this heartbeat activity. Can be "coding",
|
||||||
"building", "debugging", "running tests", "browsing",
|
"building", "debugging", "running tests", "browsing",
|
||||||
"code reviewing" or "designing". Defaults to "coding".
|
"code reviewing", "designing" or "indexing". Defaults
|
||||||
|
to "coding".
|
||||||
--proxy PROXY Optional proxy configuration. Supports HTTPS and SOCKS
|
--proxy PROXY Optional proxy configuration. Supports HTTPS and SOCKS
|
||||||
proxies. For example: https://user:pass@host:port or
|
proxies. For example: https://user:pass@host:port or
|
||||||
socks5://user:pass@host:port or domain\user:pass
|
socks5://user:pass@host:port or domain\user:pass
|
||||||
|
|
|
@ -510,6 +510,7 @@ class ArgumentsTestCase(TestCase):
|
||||||
'browsing',
|
'browsing',
|
||||||
'code reviewing',
|
'code reviewing',
|
||||||
'designing',
|
'designing',
|
||||||
|
'indexing',
|
||||||
]
|
]
|
||||||
|
|
||||||
for category in valid_categories:
|
for category in valid_categories:
|
||||||
|
|
|
@ -88,8 +88,9 @@ def parse_arguments():
|
||||||
action=StoreWithoutQuotes,
|
action=StoreWithoutQuotes,
|
||||||
help='Category of this heartbeat activity. Can be ' +
|
help='Category of this heartbeat activity. Can be ' +
|
||||||
'"coding", "building", "debugging", ' +
|
'"coding", "building", "debugging", ' +
|
||||||
'"running tests", "browsing", "code reviewing" ' +
|
'"running tests", "browsing", ' +
|
||||||
' or "designing". Defaults to "coding".')
|
'"code reviewing", "designing" or "indexing". ' +
|
||||||
|
'Defaults to "coding".')
|
||||||
parser.add_argument('--proxy', dest='proxy', action=StoreWithoutQuotes,
|
parser.add_argument('--proxy', dest='proxy', action=StoreWithoutQuotes,
|
||||||
help='Optional proxy configuration. Supports HTTPS '+
|
help='Optional proxy configuration. Supports HTTPS '+
|
||||||
'and SOCKS proxies. For example: '+
|
'and SOCKS proxies. For example: '+
|
||||||
|
|
|
@ -68,6 +68,7 @@ class Heartbeat(object):
|
||||||
'browsing',
|
'browsing',
|
||||||
'code reviewing',
|
'code reviewing',
|
||||||
'designing',
|
'designing',
|
||||||
|
'indexing',
|
||||||
]
|
]
|
||||||
if self.category not in allowed_categories:
|
if self.category not in allowed_categories:
|
||||||
self.category = None
|
self.category = None
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue