Enhancement - cal symlink

- Automatically runs "task calendar ..." if "task" is symlinked to "cal".
- Allows task to run as a replacement to Unix cal.
This commit is contained in:
Paul Beckingham 2009-06-27 12:39:05 -04:00
parent 518aea870f
commit 7e0a1759f9

View file

@ -71,7 +71,11 @@ void Context::initialize (int argc, char** argv)
// Capture the args. // Capture the args.
for (int i = 0; i < argc; ++i) for (int i = 0; i < argc; ++i)
if (i == 0) if (i == 0)
{
program = argv[i]; program = argv[i];
if (program.find ("cal") != std::string::npos)
args.push_back ("calendar");
}
else else
args.push_back (argv[i]); args.push_back (argv[i]);