gitporcelain

package
v0.52.1 Latest Latest
Warning

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

Go to latest
Published: Nov 27, 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 gitporcelain holds small shared helpers for parsing git's porcelain output. Both the runtime's working-tree scans and the acceptance reconciler read `git status --porcelain` lines; with core.quotePath=true (git's default) any path with a non-ASCII or special character is emitted C-quoted ("caf\303\251.txt"), which a naive parser would treat as a literal path.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Unquote

func Unquote(p string) string

Unquote decodes a path as git porcelain output prints it when core.quotePath is active: wrapped in double quotes with C-style escapes (\t, \", \\ and \nnn octal bytes). Git's escapes are a subset of Go's string-literal escapes, so strconv.Unquote decodes them directly. A path git did not quote — or a malformed quote — is returned unchanged.

Types

This section is empty.

Jump to

Keyboard shortcuts

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