Documentation
¶
Overview ¶
Package temp handles temporary file and directory management.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckGitignore ¶
CheckGitignore checks if .start/temp is in .gitignore. Returns true if it appears to be ignored.
Types ¶
type Manager ¶
type Manager struct {
// BaseDir is the base directory for temp files.
// For dry-run: /tmp
// For UTD: .start/temp
BaseDir string
}
Manager handles temporary file creation and management.
func NewDryRunManager ¶
func NewDryRunManager() *Manager
NewDryRunManager creates a manager for dry-run output files. Files are written to /tmp/start-YYYYMMDDHHmmss/
func NewUTDManager ¶
NewUTDManager creates a manager for UTD temp files. Files are written to .start/temp/
func (*Manager) DryRunDir ¶
DryRunDir creates a timestamped directory for dry-run output. Returns the directory path.
func (*Manager) EnsureUTDDir ¶
EnsureUTDDir ensures the UTD temp directory exists.
func (*Manager) WriteDryRunFiles ¶
WriteDryRunFiles writes the dry-run output files.
func (*Manager) WriteUTDFile ¶
WriteUTDFile writes a temp file with a path-derived name. entityType is "role", "context", or "task". name is the entity name (e.g., "code-reviewer"). Returns the path to the written file.