Documentation
¶
Index ¶
- Variables
- func DefaultConfigLocation() string
- type Config
- type Container
- func (d *Container) Config() Config
- func (d *Container) DoneTxtRepo() *todotxt.Repo
- func (d *Container) Editor() Editor
- func (d *Container) NotesRepo() *todotxt.NotesRepo
- func (d *Container) Projector(cmd *cobra.Command) qprojection.Projector
- func (d *Container) QuestScoreCalculator() qscore.Calculator
- func (d *Container) SetConfig(c Config)
- func (d *Container) SetEditor(e Editor)
- func (d *Container) SortCompiler() qsort.Compiler
- func (d *Container) TodoTxtRepo() *todotxt.Repo
- type Editor
- type EditorFunc
- type MacroDef
- type StyleDef
- type TagDef
- type ViewDef
Constants ¶
This section is empty.
Variables ¶
View Source
var InternalEditTag = "quest-object-id"
Functions ¶
func DefaultConfigLocation ¶ added in v0.4.0
func DefaultConfigLocation() string
Types ¶
type Config ¶
type Config struct {
TodoFile string `mapstructure:"todo-file,omitempty"`
DoneFile string `mapstructure:"done-file,omitempty"`
KeepBackups int `mapstructure:"backup"`
Editor string `mapstructure:"editor,omitempty"`
UnknownTags bool `mapstructure:"unknown-tags,omitempty"`
ClearOnDone []string `mapstructure:"clear-on-done,omitempty"`
QuestScore struct {
MinPriority string `mapstructure:"min-priority,omitempty"`
UrgencyTags []string `mapstructure:"urgency-tags,omitempty"`
UrgencyBegin int `mapstructure:"urgency-begin,omitempty"`
UrgencyDefault string `mapstructure:"urgency-default,omitempty"`
} `mapstructure:"quest-score,omitempty"`
Tracking struct {
Tag string `mapstructure:"tag,omitempty"`
IncludeTags []string `mapstructure:"include-tags,omitempty"`
TrimProjectPrefix bool `mapstructure:"trim-project-prefix,omitempty"`
TrimContextPrefix bool `mapstructure:"trim-context-prefix,omitempty"`
} `mapstructure:"tracking,omitempty"`
Recurrence struct {
RecTag string `mapstructure:"rec-tag,omitempty"`
DueTag string `mapstructure:"due-tag,omitempty"`
ThresholdTag string `mapstructure:"threshold-tag,omitempty"`
PreservePriority bool `mapstructure:"preserve-priority,omitempty"`
} `mapstructure:"recurrence,omitempty"`
Notes struct {
Tag string `mapstructure:"tag,omitempty"`
Dir string `mapstructure:"dir,omitempty"`
IdLength int `mapstructure:"id-length,omitempty"`
} `mapstructure:"notes,omitempty"`
Styles []StyleDef `mapstructure:"styles"`
DefaultView ViewDef `mapstructure:"default-view,omitempty"`
Views map[string]ViewDef `mapstructure:"views,omitempty"`
Macros []MacroDef `mapstructure:"macro,omitempty"`
Tags map[string]TagDef `mapstructure:"tags,omitempty"`
NowFunc func() time.Time `mapstructure:"now-func,omitempty"` // Manually set only in testing, but defaults to time.Now
}
func (Config) HumanizedTags ¶
func (Config) LineColors ¶
func (c Config) LineColors() qprojection.ColorFunc
type Container ¶
type Container struct {
ConfigFile string
// contains filtered or unexported fields
}
func (*Container) DoneTxtRepo ¶
func (*Container) Projector ¶
func (d *Container) Projector(cmd *cobra.Command) qprojection.Projector
func (*Container) QuestScoreCalculator ¶
func (d *Container) QuestScoreCalculator() qscore.Calculator
func (*Container) SortCompiler ¶
func (*Container) TodoTxtRepo ¶
type EditorFunc ¶
func (EditorFunc) Edit ¶
func (e EditorFunc) Edit(path string) error
type MacroDef ¶
type ViewDef ¶
type ViewDef struct {
Description string `mapstructure:"description,omitempty"`
Query string `mapstructure:"query,omitempty"`
Projection []string `mapstructure:"projection,omitempty"`
Sort []string `mapstructure:"sort,omitempty"`
Clean []string `mapstructure:"clean,omitempty"`
Limit int `mapstructure:"limit,omitempty"`
Interactive bool `mapstructure:"interactive,omitempty"`
AddPrefix string `mapstructure:"add-prefix,omitempty"`
AddSuffix string `mapstructure:"add-suffix,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.