shells

package
v0.14.1 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AppendLine

func AppendLine(file string, line string) error

AppendLine writes a line to a file if it does not already exist

func GetBashConfigFile

func GetBashConfigFile() (string, error)

func GetFishConfigFile

func GetFishConfigFile() (string, error)

func GetZshConfigFile

func GetZshConfigFile() (string, error)

func RemoveLine

func RemoveLine(file string, line string) error

RemoveLine removes a line from a file if it exists

Types

type ErrLineAlreadyExists

type ErrLineAlreadyExists struct {
	File string
}

func (*ErrLineAlreadyExists) Error

func (e *ErrLineAlreadyExists) Error() string

type ErrLineNotFound

type ErrLineNotFound struct {
	File string
}

func (*ErrLineNotFound) Error

func (e *ErrLineNotFound) Error() string

Jump to

Keyboard shortcuts

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