helper: Added :yesterday hint

This commit is contained in:
Paul Beckingham 2016-04-22 22:38:50 -04:00
parent e7dd8edf26
commit 7f9f29ee86
2 changed files with 7 additions and 5 deletions

View file

@ -97,11 +97,12 @@ bool expandIntervalHint (
{ {
static std::map <std::string, std::vector <std::string>> hints static std::map <std::string, std::vector <std::string>> hints
{ {
{":day", {"today", "tomorrow"}}, {":yesterday", {"yesterday", "today"}},
{":week", {"socw", "eocw"}}, {":day", {"today", "tomorrow"}},
{":month", {"socw", "eocw"}}, {":week", {"socw", "eocw"}},
{":quarter", {"socw", "eocw"}}, {":month", {"socw", "eocw"}},
{":year", {"socw", "eocw"}}, {":quarter", {"socw", "eocw"}},
{":year", {"socw", "eocw"}},
}; };
if (hints.find (hint) != hints.end ()) if (hints.find (hint) != hints.end ())

View file

@ -82,6 +82,7 @@ void initializeEntities (CLI& cli)
// Hint entities. // Hint entities.
cli.entity ("hint", ":debug"); cli.entity ("hint", ":debug");
cli.entity ("hint", ":quiet"); cli.entity ("hint", ":quiet");
cli.entity ("hint", ":yesterday");
cli.entity ("hint", ":day"); cli.entity ("hint", ":day");
cli.entity ("hint", ":week"); cli.entity ("hint", ":week");
cli.entity ("hint", ":month"); cli.entity ("hint", ":month");