Documentation
¶
Overview ¶
Package stn is a library for processing Simple Timesheet Notation.
stn.go - implements a version of Simple Timesheet Notation as a Go package. @author R. S. Doiel, <rsdoiel@gmail.com> copyright (c) 2021 all rights reserved. Released under the BSD 2-Clause license See: http://opensource.org/licenses/BSD-2-Clause
Index ¶
Constants ¶
const ( // Version number of release Version = "0.0.14" // ReleaseDate, the date version.go was generated ReleaseDate = "2025-12-03" // ReleaseHash, the Git hash when version.go was generated ReleaseHash = "80e55af" LicenseText = `` /* 1297-byte string literal not displayed */ )
const (
DateFmt = `2006-01-02`
)
Version of stn.go package.
Variables ¶
This section is empty.
Functions ¶
func FmtHelp ¶ added in v0.0.13
func FmtHelp(src string, appName string, version string, releaseDate string, releaseHash string) string
FmtHelp lets you process a text block with simple curly brace markup.
func IsDateLine ¶
IsDateLine validates a line as appropriate to pass to ParseDateLine.
func ParseDateLine ¶
ParseDateLine sets the current date context when parsing Simple Timesheet Notation elements. It is what is recorded in Occurrence field of an Entry.
Types ¶
type Entry ¶
type Entry struct {
Start time.Time
End time.Time
Annotations []string // cells of contextual data (e.g. project, activity, notes)
}
Entry is the basic data element generated when parsing a file contactining Simple Timesheet Notation. It is designed to easily turning to JSON, CSV or other useful formats.
func ParseEntry ¶
ParseEntry takes a string and the active date as a string and returns a Entry structure and error value.
func (*Entry) FromString ¶
FromString reads a tab delimited string formatted with Stringback into a Entry struct
func (*Entry) IsInRange ¶
IsInRange checks the start and end times of an Entry structure to see if it is in the time range
Directories
¶
| Path | Synopsis |
|---|---|
|
C
|
|
|
lib
command
stn.go - is a shared library to make the stn package available as a Python3 module via ctypes.
|
stn.go - is a shared library to make the stn package available as a Python3 module via ctypes. |
|
cmd
|
|
|
stnfilter
command
stnfilter.go - Simple Timesheet Notation filter.
|
stnfilter.go - Simple Timesheet Notation filter. |
|
stnparse
command
stnparse.go - Simple Timesheet Notation parser.
|
stnparse.go - Simple Timesheet Notation parser. |
|
stnreport
command
stnreport.go - Reporting tool for Simple Timesheet Notation.
|
stnreport.go - Reporting tool for Simple Timesheet Notation. |
|
libstn.go - is a shared library to make the stn package available to other programming languages such as Python3 and Julia.
|
libstn.go - is a shared library to make the stn package available to other programming languages such as Python3 and Julia. |
|
Package report provides basic report rendering for Simple Timesheet Notation.
|
Package report provides basic report rendering for Simple Timesheet Notation. |