core

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: 5 Imported by: 0

Documentation

Overview

Package core provides shared helpers for the load command: file sorting, title conversion, and output formatting.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FileNameToTitle

func FileNameToTitle(name string) string

FileNameToTitle converts a context file name to a human-readable title.

Transforms SCREAMING_SNAKE_CASE.md filenames into Title Case strings suitable for display (e.g., "TASKS.md" -> "Tasks", "AGENT_PLAYBOOK.md" -> "Agent Playbook").

Parameters:

  • name: File name to convert (with or without .md extension)

Returns:

  • string: Title case representation of the file name

func SortByReadOrder

func SortByReadOrder(files []entity.FileInfo) []entity.FileInfo

SortByReadOrder sorts context files according to [config.ReadOrder].

Files not in the read-order list are assigned a low priority (100) and will appear at the end. The original slice is not modified; a new sorted slice is returned.

Parameters:

  • files: Context files to sort

Returns:

  • []entity.FileInfo: New slice with files sorted by read priority

Types

This section is empty.

Jump to

Keyboard shortcuts

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