From aab6e690da587d54301225705ea5ee97512a49e0 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Tue, 23 Oct 2018 12:40:03 -0400 Subject: textproton: Add godoc comments --- textproto/types.go | 38 ++++++++++++++++++++++++++++---------- 1 file changed, 28 insertions(+), 10 deletions(-) (limited to 'textproto/types.go') diff --git a/textproto/types.go b/textproto/types.go index fb5aa5f..20aa3e5 100644 --- a/textproto/types.go +++ b/textproto/types.go @@ -1,4 +1,4 @@ -// Copyright (C) 2017 Luke Shumaker +// Copyright (C) 2017-2018 Luke Shumaker // // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU Affero General Public License as published by @@ -22,8 +22,11 @@ import ( "time" ) -// BUG(lukeshu): Only supports the "raw" date format (not "rfc2822" or -// "now") +// Ident is a tuple of a commiter's (or author's) name, email, and a +// timestamp with timezone. +// +// BUG(lukeshu): Ident (and ParseIdent) only supports the "raw" date +// format (not "rfc2822" or "now") type Ident struct { Name string Email string @@ -46,6 +49,16 @@ func (ut Ident) String() string { } } +// ParseIdent parses a string containing an Ident. +// +// The format of this string is +// +// SP LT GT SP