search

package
v0.14.0 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package search implements files-only search (SPEC §7.1): ripgrep when a real rg binary is on PATH, otherwise a built-in walker. Used for note full-text search and for backlink scanning. Task list/filter/sort do NOT go through here — those parse the whole tasks file into structs (see cmd list).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HasRipgrep

func HasRipgrep() bool

HasRipgrep reports whether a real rg executable is available.

Types

type Hit

type Hit struct {
	Path string
	Line int
	Text string
}

Hit is one matching line.

func Literal

func Literal(query string, paths ...string) ([]Hit, error)

Literal searches paths (files or directories) for a fixed substring, case-insensitively. It prefers ripgrep and falls back to a built-in walk.

Jump to

Keyboard shortcuts

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