mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
CLI
- Stubbed ::aliasExpansion. - Fixed variable types. - Added ::dump calls.
This commit is contained in:
parent
9a2bcbed3e
commit
1639e6bb68
2 changed files with 11 additions and 2 deletions
12
src/CLI.cpp
12
src/CLI.cpp
|
@ -62,6 +62,7 @@ void CLI::initialize (int argc, const char** argv)
|
||||||
for (int i = 1; i < argc; ++i)
|
for (int i = 1; i < argc; ++i)
|
||||||
_args.push_back (argv[i]);
|
_args.push_back (argv[i]);
|
||||||
|
|
||||||
|
dump ("CLI::initialize");
|
||||||
extractOverrides ();
|
extractOverrides ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -79,9 +80,9 @@ void CLI::extractOverrides ()
|
||||||
}
|
}
|
||||||
else if (i->find ("rc.") == 0)
|
else if (i->find ("rc.") == 0)
|
||||||
{
|
{
|
||||||
std::string::size_type sep = arg.find ('=', 3);
|
std::string::size_type sep = i->find ('=', 3);
|
||||||
if (sep == std::string::npos)
|
if (sep == std::string::npos)
|
||||||
sep = arg.find (':', 3);
|
sep = i->find (':', 3);
|
||||||
if (sep != std::string::npos)
|
if (sep != std::string::npos)
|
||||||
_overrides[i->substr (3, sep - 3)] = i->substr (sep + 1);
|
_overrides[i->substr (3, sep - 3)] = i->substr (sep + 1);
|
||||||
}
|
}
|
||||||
|
@ -90,6 +91,13 @@ void CLI::extractOverrides ()
|
||||||
}
|
}
|
||||||
|
|
||||||
_args = reconstructed;
|
_args = reconstructed;
|
||||||
|
dump ("CLI::extractOverrides");
|
||||||
|
}
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
void CLI::aliasExpansion ()
|
||||||
|
{
|
||||||
|
dump ("CLI::aliasExpansion");
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
|
@ -41,6 +41,7 @@ public:
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void extractOverrides ();
|
void extractOverrides ();
|
||||||
|
void aliasExpansion ();
|
||||||
void dump (const std::string&) const;
|
void dump (const std::string&) const;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue