format

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package format detects the file format for diff operations.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Detect

func Detect(fileA, fileB string) node.Format

Detect infers the diff format from file extensions. The extension of fileB (the "new" file) takes precedence. Returns FormatText for unrecognised extensions.

func Parse

func Parse(flag, fileA, fileB string) node.Format

Parse converts a flag value to a Format, defaulting to auto-detection.

Types

This section is empty.

Jump to

Keyboard shortcuts

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