Compare commits

..

26 Commits

Author SHA1 Message Date
Paul Beckingham
6673e408a2 - Now uses "defaultwidth" configuration variable for when ncurses support is not available
- Added the new movie to the task.html page
2008-06-19 22:41:09 -04:00
Paul Beckingham
422ad576ea - Added latest bug fix details. 2008-06-19 21:23:15 -04:00
Paul Beckingham
c1a1d13aab - Updated version 1.3.0 to 1.4.0
- Applied "showage" configuration variable to long list
2008-06-19 21:21:21 -04:00
Paul Beckingham
42189ce998 - Added some idea details 2008-06-19 21:01:14 -04:00
Paul Beckingham
43287d7fc9 - Corrected AUTHORS file
- Added new commands to task.html
2008-06-18 01:08:34 -04:00
Paul Beckingham
06f6aaaded - Minor doc updates before 1.3.0 is cut. 2008-06-18 00:45:12 -04:00
Paul Beckingham
0c17986303 - Added "task oldest" command
- Added "task newest" command
2008-06-18 00:41:33 -04:00
Paul Beckingham
feb9959907 - Added new bug fixes to task.html 2008-06-18 00:08:53 -04:00
Paul Beckingham
7409e23ce0 - Displays shorter message when a command is entered incorrectly, and the full usage for "task help". 2008-06-18 00:05:51 -04:00
Paul Beckingham
4572c97c9d - Fixed bug whereby "1 wks" was being improperly pluralized 2008-06-17 23:56:39 -04:00
Paul Beckingham
9bca303113 - Factored out filtering code. 2008-06-17 23:40:37 -04:00
Paul Beckingham
7fb3ab0c3d - Marked bug as fixed. 2008-06-17 23:05:41 -04:00
Paul Beckingham
56037fe3bc - Added latest bug fix. 2008-06-17 23:03:50 -04:00
Paul Beckingham
a2f8ce41cf - Began full command line parser BNF grammar. 2008-06-17 22:54:04 -04:00
Paul Beckingham
598bd3b4ef - Fixed crash bug in Date::toString
- New ideas file.
2008-06-17 22:23:31 -04:00
Paul Beckingham
315a7d69fb - Updated ChangeLog
- Removed AdSense HTML fragment
- Created new ideas.txt file to illustrate usage of proposed features
2008-06-17 22:10:07 -04:00
Paul Beckingham
64fff6c2ff - Added Google Analytics. 2008-06-17 22:03:38 -04:00
Paul Beckingham
969ecd7b5d Merge branch 'master' into 1.3.0 2008-06-17 18:48:23 -04:00
Paul Beckingham
cede865693 - Partial fix to bug - snapshot. 2008-06-17 18:28:24 -04:00
Paul Beckingham
d68395bc51 - Fixed bug whereby if you have more than one task with a due date, 7 days gets added to the entry date of task 2..n 2008-06-17 17:52:12 -04:00
Paul Beckingham
7ec523d5ea - Removed unused std::vector forms of get/set
- Added more defaults to Config::createDefault
2008-06-16 23:37:32 -04:00
Paul Beckingham
08fc906d5f - Updated various documents. 2008-06-16 23:26:22 -04:00
Paul Beckingham
f3e995ef92 Merge branch 'damian' into 1.3.0 2008-06-16 22:26:20 -04:00
Paul Beckingham
a4304c97af - Corrected the "30 days in August" bug.
- Removed odd styling from task.html CSS.
2008-06-16 22:24:49 -04:00
Paul Beckingham
d1ef0d17d5 - Integrated Damian Glenny's changes 2008-06-15 18:38:01 -04:00
Paul Beckingham
c54cb4d6c8 - Bumped version to 1.3.0 2008-06-14 13:55:35 -04:00
17 changed files with 1052 additions and 705 deletions

View File

@@ -1,10 +1,14 @@
Principal Author:
Paul Beckingham, paul@beckingham.net
Contributing Authors:
Damian Glenny
With thanks to:
Eugene Kramer
SK
Damian Glenny
Srijith K
Richard Querin
Bruce Israel
Thomas Engel
Nishiishii

View File

@@ -7,10 +7,32 @@ represents a feature release, and the z represents a patch.
------ plans -------------------------------------
Configurable columns in reports
- Configurable columns in reports
- Dependencies
1.4.0 (?)
+ Bug: "showage" configuration variable should apply to all reprts, not
just the ones based on "list"
+ New configuration variable, "defaultwidth" that determines the width
of tables when ncurses support is not available
------ reality -----------------------------------
1.3.0 (6/18/2008)
+ "task calendar" now displays multiple months per line, adjustable by the
"monthsperline" configuration variable. Feature added by Damian Glenny
+ "task export" can now filter tasks like the reports
+ Factored out code to filter tasks
+ Displays shorter message when a command is entered incorrectly, and the
full usage for "task help"
+ "task oldest" shows the oldest tasks
+ "task newest" shows the newest tasks
+ Bug: Segmentation fault when no "dateformat" configuration variable
specified
+ Bug: Fixed bug whereby if you have more than one task with a due date, 7
days gets added to the entry date of task 2..n
+ Bug: Fixed bug whereby "1 wks" was being improperly pluralized
1.2.0 (6/13/2008)
+ Bug: "dateformat" configuration variable used to display dates, but
not parse them

2
NEWS
View File

@@ -1,4 +1,4 @@
Welcome to Task 1.2.0.
Welcome to Task 1.4.0.
Task has been built and tested on the following configurations:

View File

@@ -1,4 +1,4 @@
Task program tutorial, for version 1.2.0
Task program tutorial, for version 1.4.0
----------------------------------------
This guide shows how to quickly set up the task program, and become proficient
@@ -21,10 +21,10 @@ Build the task program according to the directions in the INSTALL file. This
transcript illustrates a typical installation:
% ls
task-1.2.0.tar.gz
% gunzip task-1.2.0.tar.gz
% tar xf task-1.2.0.tar
% cd task-1.2.0
task-1.4.0.tar.gz
% gunzip task-1.4.0.tar.gz
% tar xf task-1.4.0.tar
% cd task-1.4.0
% ./configure
...
% make
@@ -379,6 +379,22 @@ with no arguments will generate a help message that lists all these commands.
% task oldest
-------------
Lists the oldest tasks. Shows 10 tasks by default, but can be set via the
"oldest" configuration variable.
% task newest
-------------
Lists the newest tasks. Shows 10 tasks by default, but can be set via the
"newest" configuration variable.
% task history
--------------
@@ -678,7 +694,8 @@ Configuring Task
Y four-digit year 2008
The string may also contain other characters to act as
spacers, or formatting. Other values could include:
spacers, or formatting. Other values could include
(but are not limited to):
d/m/Y 7/6/2008
YMD 20080607
@@ -687,6 +704,18 @@ Configuring Task
showage May be "yes" or "no". Determines whether the "Age"
column appears on the "list" and "next" reports.
monthsperline Determines how many months the "task calendar" command
renders across the screen. Defaults to 1.
oldest Determines how many tasks are shown on the "oldest"
report. Defaults to 10.
newest Determines how many tasks are shown on the "newest"
report. Defaults to 10.
defaultwidth The width of tables used when ncurses support is not
available. Defaults to 80.
color May be "on" or "off". Determines whether task uses
color.

View File

@@ -1,12 +0,0 @@
<script type="text/javascript"><!--
google_ad_client = "pub-9709799404235424";
/* Task Main */
google_ad_slot = "8660617875";
google_ad_width = 120;
google_ad_height = 600;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>

View File

@@ -2,7 +2,7 @@
# Process this file with autoconf to produce a configure script.
AC_PREREQ(2.61)
AC_INIT(task, 1.2.0, bugs@beckingham.net)
AC_INIT(task, 1.4.0, bugs@beckingham.net)
AM_INIT_AUTOMAKE
AC_CONFIG_SRCDIR([src/task.cpp])
AC_CONFIG_HEADER([auto.h])

68
grammar.txt Normal file
View File

@@ -0,0 +1,68 @@
This is a full BNF grammar for the task command line. It is intended that a
future release of task will incorporate a complete lexer/parser implementing
this grammar.
command:
VERSION
| HELP
| PROJECTS
| TAGS
| SUMMARY
| HISTORY
| NEXT
| CALENDAR
| ACTIVE
| OVERDUE
| STATS
| USAGE
| OLDEST
| NEWEST
| EXPORT <file>
| COLOR
| DELETE <id>
| INFO <id>
| START <id>
| DONE <id>
| ADD [<tags>] [<attrs>] [<desc>]
| LIST [<tags>] [<attrs>] [<desc>]
| LONG [<tags>] [<attrs>] [<desc>]
| LS [<tags>] [<attrs>] [<desc>]
| COMPLETED [<tags>] [<attrs>] [<desc>]
| <id> [<tags>] [<attrs>] [<desc>]
| <id> <substitution>
id:
\d+
| \d{8}-\d{4}-\d{4}-\d{12}
tags:
+<tag>
| -<tag>
tag:
\w+
attrs:
<attr>
| <attr> <attrs>
attr:
<name>:<value>
name:
\w+
value:
.+
substitution:
/ <pattern> / <pattern> /
pattern:
.+
file:
?

17
ideas.txt Normal file
View File

@@ -0,0 +1,17 @@
Real Parsing
define grammar for command line
implement flex/bison parser
User-Defined Reports
report.xxx=id,project(2+),priority(1-),description
change all list-based reports to user-defined
Generalized Report Writer
provide column list, sort order, filter
Test Suite
allow .taskrc override
debug=on to cause all cout to be csv
regression tests for every bug, command, feature

View File

@@ -116,6 +116,9 @@ void Config::createDefault (const std::string& file)
fprintf (out, "confirmation=yes\n");
fprintf (out, "#nag=Note: try to stick to high priority tasks. See \"task next\".\n");
fprintf (out, "next=2\n");
fprintf (out, "dateformat=m/d/Y\n");
fprintf (out, "showage=yes\n");
fprintf (out, "monthsperline=1\n");
fprintf (out, "curses=on\n");
fprintf (out, "color=on\n");
@@ -137,6 +140,9 @@ void Config::createDefault (const std::string& file)
set ("command.logging", "off");
set ("confirmation", "yes");
set ("next", 1);
set ("dateformat", "m/d/Y");
set ("showage", "yes");
set ("monthsperline", 3);
set ("curses", "on");
set ("color", "on");
set ("color.overdue", "red");
@@ -246,29 +252,6 @@ void Config::set (const std::string& key, const std::string& value)
(*this)[key] = value;
}
////////////////////////////////////////////////////////////////////////////////
// The vector form of Config::get assumes the single value is comma-separated,
// and splits accordingly.
void Config::get (
const std::string& key,
std::vector <std::string>& values)
{
values.clear ();
split (values, (*this)[key], ',');
}
////////////////////////////////////////////////////////////////////////////////
// The vector form of Config::set joins the values together with commas, and
// stores the single value.
void Config::set (
const std::string& key,
const std::vector <std::string>& values)
{
std::string conjoined;
join (conjoined, ",", values);
(*this)[key] = conjoined;
}
////////////////////////////////////////////////////////////////////////////////
// Provide a vector of all configuration keys.
void Config::all (std::vector<std::string>& items)

View File

@@ -47,11 +47,9 @@ public:
bool get (const std::string&, bool);
int get (const std::string&, const int);
double get (const std::string&, const double);
void get (const std::string&, std::vector <std::string>&);
void set (const std::string&, const int);
void set (const std::string&, const double);
void set (const std::string&, const std::string&);
void set (const std::string&, const std::vector <std::string>&);
void all (std::vector <std::string>&);
};

View File

@@ -57,7 +57,7 @@ Date::Date (const int m, const int d, const int y)
}
////////////////////////////////////////////////////////////////////////////////
Date::Date (const std::string& mdy, const std::string format /* = "m/d/Y" */)
Date::Date (const std::string& mdy, const std::string& format /* = "m/d/Y" */)
{
int month = 0;
int day = 0;
@@ -221,65 +221,29 @@ void Date::toMDY (int& m, int& d, int& y)
}
////////////////////////////////////////////////////////////////////////////////
std::string Date::toString (const std::string& format /*= "m/d/Y"*/)
const std::string Date::toString (const std::string& format /*= "m/d/Y" */) const
{
// Making this local copy seems to fix a bug. Remove the local copy and you'll
// see segmentation faults and all kinds of gibberish.
std::string localFormat = format;
char buffer[12];
std::string formatted;
for (unsigned int i = 0; i < format.length (); ++i)
for (unsigned int i = 0; i < localFormat.length (); ++i)
{
switch (format[i])
char c = localFormat[i];
switch (c)
{
case 'm':
{
char m[3];
sprintf (m, "%d", this->month ());
formatted += m;
}
break;
case 'M':
{
char m[3];
sprintf (m, "%02d", this->month ());
formatted += m;
}
break;
case 'd':
{
char d[3];
sprintf (d, "%d", this->day ());
formatted += d;
}
break;
case 'D':
{
char d[3];
sprintf (d, "%02d", this->day ());
formatted += d;
}
break;
case 'y':
{
char y[3];
sprintf (y, "%02d", this->year () % 100);
formatted += y;
}
break;
case 'Y':
{
char y[5];
sprintf (y, "%d", this->year ());
formatted += y;
}
break;
default:
formatted += format[i];
break;
case 'm': sprintf (buffer, "%d", this->month ()); break;
case 'M': sprintf (buffer, "%02d", this->month ()); break;
case 'd': sprintf (buffer, "%d", this->day ()); break;
case 'D': sprintf (buffer, "%02d", this->day ()); break;
case 'y': sprintf (buffer, "%02d", this->year () % 100); break;
case 'Y': sprintf (buffer, "%d", this->year ()); break;
default: sprintf (buffer, "%c", c); break;
}
formatted += buffer;
}
return formatted;

View File

@@ -37,14 +37,14 @@ public:
Date ();
Date (time_t);
Date (const int, const int, const int);
Date (const std::string&, const std::string format = "m/d/Y");
Date (const std::string&, const std::string& format = "m/d/Y");
Date (const Date&);
virtual ~Date ();
void toEpoch (time_t&);
time_t toEpoch ();
void toMDY (int&, int&, int&);
std::string toString (const std::string& format = "m/d/Y");
const std::string toString (const std::string& format = "m/d/Y") const;
static bool valid (const int, const int, const int);
static bool leapYear (int);

View File

@@ -120,12 +120,15 @@ static const char* commands[] =
"delete",
"done",
"export",
"help",
"history",
"info",
"list",
"long",
"ls",
"newest",
"next",
"oldest",
"overdue",
"projects",
"start",

File diff suppressed because it is too large Load Diff

View File

@@ -36,6 +36,10 @@
#include "T.h"
#include "../auto.h"
#ifndef min
#define min(a,b) ((a) < (b) ? (a) : (b))
#endif
#ifndef max
#define max(a,b) ((a) > (b) ? (a) : (b))
#endif
@@ -69,6 +73,8 @@ void handleReportCalendar (const TDB&, T&, Config&);
void handleReportActive (const TDB&, T&, Config&);
void handleReportOverdue (const TDB&, T&, Config&);
void handleReportStats (const TDB&, T&, Config&);
void handleReportOldest (const TDB&, T&, Config&);
void handleReportNewest (const TDB&, T&, Config&);
void handleVersion (Config&);
void handleExport (const TDB&, T&, Config&);
void handleDelete (const TDB&, T&, Config&);

View File

@@ -80,19 +80,19 @@ void formatTimeDeltaDays (std::string& output, time_t delta)
if (days > 365)
sprintf (formatted, "%.1f yrs", (days / 365.2422));
else if (days > 84)
sprintf (formatted, "%1d mths", (int) (days / 30.6));
sprintf (formatted, "%1d mth%s", (int) (days / 30.6), ((int) (days / 30.6) == 1 ? "" : "s"));
else if (days > 13)
sprintf (formatted, "%d wks", (int) (days / 7.0));
sprintf (formatted, "%d wk%s", (int) (days / 7.0), ((int) (days / 7.0) == 1 ? "" : "s"));
else if (days > 5.0)
sprintf (formatted, "%d days", (int) days);
sprintf (formatted, "%d day%s", (int) days, ((int) days == 1 ? "" : "s"));
else if (days > 1.0)
sprintf (formatted, "%.1f days", days);
else if (days * 24 > 1.0)
sprintf (formatted, "%d hrs", (int) (days * 24.0));
sprintf (formatted, "%d hr%s", (int) (days * 24.0), ((int) (days * 24.0) == 1 ? "" : "s"));
else if (days * 24 * 60 > 1)
sprintf (formatted, "%d mins", (int) (days * 24 * 60));
sprintf (formatted, "%d min%s", (int) (days * 24 * 60), ((int) (days * 24 * 60) == 1 ? "" : "s"));
else if (days * 24 * 60 * 60 > 1)
sprintf (formatted, "%d secs", (int) (days * 24 * 60 * 60));
sprintf (formatted, "%d sec%s", (int) (days * 24 * 60 * 60), ((int) (days * 24 * 60 * 60) == 1 ? "" : "s"));
else
strcpy (formatted, "-");
@@ -108,19 +108,19 @@ std::string formatSeconds (time_t delta)
if (days > 365)
sprintf (formatted, "%.1f yrs", (days / 365.2422));
else if (days > 84)
sprintf (formatted, "%1d mths", (int) (days / 30.6));
sprintf (formatted, "%1d mth%s", (int) (days / 30.6), ((int) (days / 30.6) == 1 ? "" : "s"));
else if (days > 13)
sprintf (formatted, "%d wks", (int) (days / 7.0));
sprintf (formatted, "%d wk%s", (int) (days / 7.0), ((int) (days / 7.0) == 1 ? "" : "s"));
else if (days > 5.0)
sprintf (formatted, "%d days", (int) days);
sprintf (formatted, "%d day%s", (int) days, ((int) days == 1 ? "" : "s"));
else if (days > 1.0)
sprintf (formatted, "%.1f days", days);
else if (days * 24 > 1.0)
sprintf (formatted, "%d hrs", (int) (days * 24.0));
sprintf (formatted, "%d hr%s", (int) (days * 24.0), ((int) (days * 24) == 1 ? "" : "s"));
else if (days * 24 * 60 > 1)
sprintf (formatted, "%d mins", (int) (days * 24 * 60));
sprintf (formatted, "%d min%s", (int) (days * 24 * 60), ((int) (days * 24 * 60) == 1 ? "" : "s"));
else if (days * 24 * 60 * 60 > 1)
sprintf (formatted, "%d secs", (int) (days * 24 * 60 * 60));
sprintf (formatted, "%d sec%s", (int) (days * 24 * 60 * 60), ((int) (days * 24 * 60 * 60) == 1 ? "" : "s"));
else
strcpy (formatted, "-");

116
task.html
View File

@@ -1,7 +1,7 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Task 1.2.0</title>
<title>Task 1.4.0</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<style type="text/css">
body {
@@ -74,7 +74,6 @@ body {
#content h4 {
font-size: 18px;
margin: 1.2em 0 0.3em;
border-bottom: 1px dotted #bbb;
}
#content h5 {
@@ -166,14 +165,50 @@ a img { border: none; padding: 0; margin: 0; }
<h2 class="title">Get the Source Code</h2>
<div class="content">
<p>
Download the latest task source code
<a href="http://www.beckingham.net/task-1.2.0.tar.gz">task-1.2.0.tar.gz</a>
(6/13/2008).
Download the
<a href="http://www.beckingham.net/task-1.4.0.tar.gz">latest version</a>
of the task source code (6/18/2008).
</p>
<p>
<h4>New in version 1.4.0</h4>
Source: <a href="http://www.beckingham.net/task-1.4.0.tar.gz">task-1.4.0.tar.gz</a>
</p>
<ul>
<li>Fixed bug where "showage" configuration variable was not being
oberved by the "task long" report
<li>New configuration variable "defaultwidth" determines the width
of windows in the absense of ncurses support
</ul>
<p>
<h4>New in version 1.3.0</h4>
Source: <a href="http://www.beckingham.net/task-1.3.0.tar.gz">task-1.3.0.tar.gz</a>
</p>
<ul>
<li>"task calendar" now displays multiple months per line, adjustable
by the "monthsperline" configuration variable. Feature added by
Damian Glenny
<li>Displays shorter message when a command is entered incorrectly,
and the full usage for "task help"
<li>"task export" can now filter tasks like the reports
<li>"task oldest" shows the oldest tasks
<li>"task newest" shows the newest tasks
<li>Fixed bug where task generates a segmentation fault for several
commands, when no "dateformat" configuration variable was present
<li>Fixed bug whereby if you have more than one task with a due date,
7 days gets added to the entry date of task 2..n
<li>Fixed bug whereby "1 wks" was being improperly pluralized
</ul>
<p>
<h4>New in version 1.2.0</h4>
source: <a href="http://www.beckingham.net/task-1.2.0.tar.gz">task-1.2.0.tar.gz</a>
Source: <a href="http://www.beckingham.net/task-1.2.0.tar.gz">task-1.2.0.tar.gz</a>
<br />
Debian package: <a href="http://www.beckingham.net/task_1.2.0-1_i386.deb">task_1.2.0-1_i386.deb</a>
(Thanks to <a href="http://blog.rfquerin.org">Richard Querin</a>)
</p>
<ul>
@@ -190,10 +225,10 @@ a img { border: none; padding: 0; margin: 0; }
<p>
<h4>New in version 1.1.0</h4>
source: <a href="http://www.beckingham.net/task-1.1.0.tar.gz">task-1.1.0.tar.gz</a>
Source: <a href="http://www.beckingham.net/task-1.1.0.tar.gz">task-1.1.0.tar.gz</a>
<br />
Debian package: <a href="http://www.beckingham.net/task_1.1.0-1_i386.deb">task_1.1.0-1_i386.deb</a>
(Thanks to Richard Querin)
(Thanks to <a href="http://blog.rfquerin.org">Richard Querin</a>)
</p>
<ul>
@@ -235,6 +270,12 @@ a img { border: none; padding: 0; margin: 0; }
This guide shows how to quickly set up the task program, and become
proficient with it.
</p>
<p>
Alternatively, watch the
<a href="http://www.youtube.com/watch?v=D2Kn4DMOVSw">task movie</a>
which illustrates many of task's features.
</p>
</div>
<br />
@@ -246,10 +287,10 @@ a img { border: none; padding: 0; margin: 0; }
</p>
<pre><code>% ls
task-1.2.0.tar.gz
% gunzip task-1.2.0.tar.gz
% tar xf task-1.2.0.tar
% cd task-1.2.0
task-1.3.0.tar.gz
% gunzip task-1.3.0.tar.gz
% tar xf task-1.3.0.tar
% cd task-1.3.0
% ./configure
...
% make
@@ -739,6 +780,18 @@ ID Project Pri Description
12 Errand L Remember to deposit bonus check
...</code></pre>
<strong>% task oldest</strong>
<p>
Lists the oldest tasks. Shows 10 tasks by default, but can be
set via the "oldest" configuration variable.
</p>
<strong>% task newest</strong>
<p>
Lists the newest tasks. Shows 10 tasks by default, but can be
set via the "newest" configuration variable.
</p>
<strong>% task /from/to/</strong>
<p>
If a task has been entered with a typo, it can be easily corrected
@@ -1024,7 +1077,7 @@ on_white on_bright_white</code></pre>
<p>
The string may also contain other characters to act as spacers,
or formatting. Other values could include:
or formatting. Other values could include (but are not limited to):
</p>
<p>
@@ -1055,6 +1108,30 @@ on_white on_bright_white</code></pre>
column appears on the "list" and "next" reports.
<dd>
<dt>monthsperline</dt>
<dd>
Determines how many months the "task calendar" command
renders across the screen. Defaults to 1.
</dd>
<dt>oldest</dt>
<dd>
Determines how many tasks the "task oldest" command displays.
Defaults to 10.
</dd>
<dt>newest</dt>
<dd>
Determines how many tasks the "task newest" command displays.
Defaults to 10.
</dd>
<dt>defaultwidth</dt>
<dd>
The width of tables used when ncurses support is not available.
Defaults to 80.
</dd>
<dt>color</dt>
<dd>
May be "on" or "off". Determines whether task uses color.
@@ -1152,6 +1229,8 @@ on_white on_bright_white</code></pre>
task calendar
task active
task overdue
task oldest
task newest
task stats
task usage
task export
@@ -1222,6 +1301,17 @@ Many characters have special meaning to the shell, including:
</table>
</div>
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
var pageTracker = _gat._getTracker("UA-4737637-1");
pageTracker._initData();
pageTracker._trackPageview();
</script>
</body>
</html>