mdline

package
v0.67.0 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2026 License: MIT Imports: 1 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package mdline reads the `key: value` lines f10 takes out of markdown that people and agents edit. The model reads `**local**: ...` and `local: ...` alike, so every Go reader goes through here to read them alike too.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Bare

func Bare(s string) string

Bare trims marks and space from both ends: `**FT-12**` is FT-12.

func Cut

func Cut(line string, seps ...string) (string, string, bool)

Cut splits a line at the earliest of seps into key, value and whether a non-empty key was found. The key loses its marks; the value keeps its code spans (some carry an identity in one), losing only a marked key's leftover emphasis; a bold label cuts after its closing `**` even with no separator.

func Item

func Item(line string) (string, bool)

Item strips a list bullet ("- ", "* ", "+ ") and the space around the line; ok is false when the line is not a list item.

func Unmark

func Unmark(s string) string

Unmark drops every emphasis star and code mark, for a phrase matched inside a paragraph rather than at the start of a line.

Types

This section is empty.

Jump to

Keyboard shortcuts

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