CmdLog: Gone

This commit is contained in:
Paul Beckingham 2016-04-06 17:36:40 -04:00
parent f7619a138d
commit aa8179654f
5 changed files with 0 additions and 75 deletions

View file

@ -26,7 +26,6 @@ set (libshared_SRCS libshared/src/Args.cpp libshared/src/Args.h
libshared/src/Duration.cpp libshared/src/Duration.h libshared/src/Duration.cpp libshared/src/Duration.h
libshared/src/FS.cpp libshared/src/FS.h libshared/src/FS.cpp libshared/src/FS.h
libshared/src/JSON.cpp libshared/src/JSON.h libshared/src/JSON.cpp libshared/src/JSON.h
libshared/src/Log.cpp libshared/src/Log.h
libshared/src/Msg.cpp libshared/src/Msg.h libshared/src/Msg.cpp libshared/src/Msg.h
libshared/src/Pig.cpp libshared/src/Pig.h libshared/src/Pig.cpp libshared/src/Pig.h
libshared/src/RX.cpp libshared/src/RX.h libshared/src/RX.cpp libshared/src/RX.h

View file

@ -38,7 +38,6 @@ int CmdHelpUsage ()
<< " timew diagnostics\n" << " timew diagnostics\n"
<< " timew export\n" << " timew export\n"
<< " timew extensions\n" << " timew extensions\n"
<< " timew log [<message>]\n"
<< " timew start [<tag> ...]\n" << " timew start [<tag> ...]\n"
<< " timew stop\n" << " timew stop\n"
<< " timew tags\n" << " timew tags\n"
@ -137,21 +136,6 @@ int CmdHelp (CLI& cli, Log& log)
// TODO gaps // TODO gaps
// TODO help // TODO help
// TODO import // TODO import
// Ruler 1 2 3 4 5 6 7 8
// 12345678901234567890123456789012345678901234567890123456789012345678901234567890
else if (words[0] == "log")
std::cout << "\n"
<< "Syntax: timew log [<message>]\n"
<< "\n"
<< "Writes the info <message> to the Timewarrior log file. The <message> may be\n"
<< "multiple words, or a quoted string. If <message> is ommitted, writes a cut\n"
<< "marker ('-------- 8< --------') line to the log file.\n"
<< "\n"
<< "Note: Your log file is found here:\n"
<< " " << log.file () << "\n"
<< "\n";
// TODO report // TODO report
// Ruler 1 2 3 4 5 6 7 8 // Ruler 1 2 3 4 5 6 7 8

View file

@ -1,55 +0,0 @@
////////////////////////////////////////////////////////////////////////////////
//
// Copyright 2015 - 2016, Paul Beckingham, Federico Hernandez.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// http://www.opensource.org/licenses/mit-license.php
//
////////////////////////////////////////////////////////////////////////////////
#include <cmake.h>
#include <commands.h>
#include <shared.h>
#include <vector>
#include <string>
#include <iostream>
////////////////////////////////////////////////////////////////////////////////
// TODO This may be removed, unless it proves useful.
int CmdLog (CLI& cli, Log& log)
{
auto words = cli.getWords ();
if (words.size ())
{
// 'timew log mark' writes a marker.
if (words[0] == "mark")
log.write ("debug", "-------- 8< --------");
// 'timew log ...' writes '...' to log.
else
log.write ("info", join (" ", words));
}
else
std::cout << "No message specified.\n";
return 0;
}
////////////////////////////////////////////////////////////////////////////////

View file

@ -44,7 +44,6 @@ int CmdExtensions ( Rules&, Extensions& );
int CmdGaps ( ); int CmdGaps ( );
int CmdHelpUsage ( ); int CmdHelpUsage ( );
int CmdHelp (CLI&, Log&); int CmdHelp (CLI&, Log&);
int CmdLog (CLI&, Log&);
int CmdImport ( ); int CmdImport ( );
int CmdReport (CLI&, Rules&, Database&, Extensions&, Log&); int CmdReport (CLI&, Rules&, Database&, Extensions&, Log&);
int CmdStart (CLI&, Rules&, Database&, Log&); int CmdStart (CLI&, Rules&, Database&, Log&);

View file

@ -65,7 +65,6 @@ void initializeEntities (CLI& cli)
cli.entity ("command", "gaps"); cli.entity ("command", "gaps");
cli.entity ("command", "help"); cli.entity ("command", "help");
cli.entity ("command", "import"); cli.entity ("command", "import");
cli.entity ("command", "log");
cli.entity ("command", "report"); cli.entity ("command", "report");
cli.entity ("command", "start"); cli.entity ("command", "start");
cli.entity ("command", "stop"); cli.entity ("command", "stop");
@ -217,7 +216,6 @@ int dispatchCommand (
else if (command == "gaps") status = CmdGaps ( ); else if (command == "gaps") status = CmdGaps ( );
else if (command == "help") status = CmdHelp (cli, log); else if (command == "help") status = CmdHelp (cli, log);
else if (command == "import") status = CmdImport ( ); else if (command == "import") status = CmdImport ( );
else if (command == "log") status = CmdLog (cli, log);
else if (command == "report") status = CmdReport (cli, rules, database, extensions, log); else if (command == "report") status = CmdReport (cli, rules, database, extensions, log);
else if (command == "start") status = CmdStart (cli, rules, database, log); else if (command == "start") status = CmdStart (cli, rules, database, log);
else if (command == "stop") status = CmdStop (cli, rules, database, log); else if (command == "stop") status = CmdStop (cli, rules, database, log);