format

package
v0.8.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 24, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package format builds timestamped Markdown entries for decisions, learnings, tasks, and conventions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Convention

func Convention(content string) string

Convention formats a convention entry as a simple Markdown list item.

Format: "- content"

Parameters:

  • content: Convention description text

Returns:

  • string: Formatted convention line with trailing newline

func Decision

func Decision(title, context, rationale, consequence string) string

Decision formats a decision entry as a structured Markdown section.

The output includes a timestamped heading, status, and complete ADR sections for context, rationale, and consequence.

Parameters:

  • title: Decision title/summary text
  • context: What prompted this decision
  • rationale: Why this choice over alternatives
  • consequence: What changes as a result

Returns:

  • string: Formatted decision section with all ADR fields

func Learning

func Learning(title, context, lesson, application string) string

Learning formats a learning entry as a structured Markdown section.

The output includes a timestamped heading and complete sections for context, lesson, and application.

Parameters:

  • title: Learning title/summary text
  • context: What prompted this learning
  • lesson: The key insight
  • application: How to apply this going forward

Returns:

  • string: Formatted learning section with all fields

func Task

func Task(content string, priority string) string

Task formats a task entry as a Markdown checkbox item.

The output includes a timestamp tag for session correlation and an optional priority tag. Format: "- [ ] content #priority:level #added:YYYY-MM-DD-HHMMSS"

Parameters:

  • content: Task description text
  • priority: Priority level (high, medium, low); empty string omits the tag

Returns:

  • string: Formatted task line with trailing newline

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL