diff --git a/DEVELOPERS b/DEVELOPERS new file mode 100644 index 000000000..9f9a42faf --- /dev/null +++ b/DEVELOPERS @@ -0,0 +1,20 @@ +Developers may wish to change task, and here is a high-level guide to the files +included. + + task.{cpp,h} Functions that implement the task commands, and main. + parse.cpp Parses the command line. + TDB.{cpp,h} The task database, performs all file I/O + T.{cpp,h} Represents a single task - parses a record from TDB, and also + composes record for TDB. Provides accessors for tasks. + Grid.{cpp,h} Implements a sparse 2D array, provides data storage for the + Table object. + Table.{cpp,h} Implements tabular data rendering, wrapping etc. + Config.{cpp,h} Implements a reader for the .taskrc file. + Date.{cpp,h} General date class for the time_t type. + text.cpp Text manipulation functions. + util.cpp General utility functions. + color.cpp Color support functions. + rules.cpp Auto-colorization rules. + +Don't forget, please send patches to task@beckingham.net + diff --git a/Makefile.am b/Makefile.am index a0d359809..685ed0a57 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,3 +1,3 @@ SUBDIRS = src -EXTRA_DIST = TUTORIAL +EXTRA_DIST = TUTORIAL DEVELOPERS diff --git a/README b/README index f94b06d72..b9a39cd13 100644 --- a/README +++ b/README @@ -1,14 +1,13 @@ -Task is a GTD utility featuring: +Thank you for taking a look at task. Task is a GTD utility featuring: - Robust C++ implementation - Tags - Colorful, tabular output - Reports - Low-level API - - Auto-completion on all commands, options + - Abbreviations for all commands, options - Multi-user file locking - Clean architecture allowing quick addition of new features - - UUID for all tasks It is intended that features, mainly in the form of reports will be added frequently, with best practices and useful reports evolving from usage patterns. @@ -17,8 +16,6 @@ Task is scope-limited to GTD functionality only. -Thank you for taking a look at task. - You may want to jump straight to the TUTORIAL file, or perhaps watch the task movie on YouTube: diff --git a/src/library.h b/src/library.h deleted file mode 100644 index 92376814e..000000000 --- a/src/library.h +++ /dev/null @@ -1,49 +0,0 @@ -//////////////////////////////////////////////////////////////////////////////// -// Copyright 2004 - 2008, Paul Beckingham. All rights reserved. -// -// -//////////////////////////////////////////////////////////////////////////////// -#ifndef INCLUDED_LIBRARY -#define INCLUDED_LIBRARY - -#include -#include -#include - -#include "stlmacros.h" - -#ifndef max -#define max(a,b) ((a) > (b) ? (a) : (b)) -#endif - -// text.cpp -void wrapText (std::vector &, const std::string&, const int); -std::string trimLeft (const std::string& in, const std::string& t = " "); -std::string trimRight (const std::string& in, const std::string& t = " "); -std::string trim (const std::string& in, const std::string& t = " "); -std::wstring trimLeft (const std::wstring& in, const std::wstring& t = L" "); // UNICODE safe -std::wstring trimRight (const std::wstring& in, const std::wstring& t = L" "); // UNICODE safe -std::wstring trim (const std::wstring& in, const std::wstring& t = L" "); // UNICODE safe -void extractParagraphs (const std::string&, std::vector&); -void extractLine (std::string&, std::string&, int); -void split (std::vector&, const std::string&, const char); -void split (std::vector&, const std::string&, const std::string&); -void join (std::string&, const std::string&, const std::vector&); -std::string commify (const std::string&); -std::string lowerCase (const std::string&); - -// misc.cpp -void delay (float); - -// list.cpp -int autoComplete (const std::string&, const std::vector&, std::vector&); - -// units.cpp -void formatTimeDeltaDays (std::string&, time_t); -std::string formatSeconds (time_t); - -// uuid.cpp -const std::string uuid (); - -#endif -//////////////////////////////////////////////////////////////////////////////// diff --git a/src/task.h b/src/task.h index 10ae35e4f..3d1b85783 100644 --- a/src/task.h +++ b/src/task.h @@ -57,9 +57,6 @@ void wrapText (std::vector &, const std::string&, const int); std::string trimLeft (const std::string& in, const std::string& t = " "); std::string trimRight (const std::string& in, const std::string& t = " "); std::string trim (const std::string& in, const std::string& t = " "); -std::wstring trimLeft (const std::wstring& in, const std::wstring& t = L" "); // UNICODE safe -std::wstring trimRight (const std::wstring& in, const std::wstring& t = L" "); // UNICODE safe -std::wstring trim (const std::wstring& in, const std::wstring& t = L" "); // UNICODE safe void extractParagraphs (const std::string&, std::vector&); void extractLine (std::string&, std::string&, int); void split (std::vector&, const std::string&, const char); diff --git a/src/text.cpp b/src/text.cpp index a5fbcc279..b169d94d2 100644 --- a/src/text.cpp +++ b/src/text.cpp @@ -99,13 +99,6 @@ std::string trimLeft (const std::string& in, const std::string& t /*= " "*/) return out.erase (0, in.find_first_not_of (t)); } -// UNICODE safe -std::wstring trimLeft (const std::wstring& in, const std::wstring& t /*= L" "*/) -{ - std::wstring out = in; - return out.erase (0, in.find_first_not_of (t)); -} - //////////////////////////////////////////////////////////////////////////////// std::string trimRight (const std::string& in, const std::string& t /*= " "*/) { @@ -113,13 +106,6 @@ std::string trimRight (const std::string& in, const std::string& t /*= " "*/) return out.erase (out.find_last_not_of (t) + 1); } -// UNICODE safe -std::wstring trimRight (const std::wstring& in, const std::wstring& t /*= L" "*/) -{ - std::wstring out = in; - return out.erase (out.find_last_not_of (t) + 1); -} - //////////////////////////////////////////////////////////////////////////////// std::string trim (const std::string& in, const std::string& t /*= " "*/) { @@ -127,13 +113,6 @@ std::string trim (const std::string& in, const std::string& t /*= " "*/) return trimLeft (trimRight (out, t), t); } -// UNICODE safe -std::wstring trim (const std::wstring& in, const std::wstring& t /*= L" "*/) -{ - std::wstring out = in; - return trimLeft (trimRight (out, t), t); -} - //////////////////////////////////////////////////////////////////////////////// // Remove enclosing balanced quotes. Assumes trimmed text. void unquoteText (std::string& text)