Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Location ¶
type Location struct { Key string Path string // filePath.join(home.GetHome, fmt.Sprintf("%s.gitconfig", Key)) ConfigFile string }
func NewLocation ¶
type LocationManager ¶
type LocationManager struct {
// contains filtered or unexported fields
}
func NewLocationManager ¶
func NewLocationManager(gitconfigPath string, fs *afero.Afero) *LocationManager
func (*LocationManager) FindLocationByKey ¶
func (t *LocationManager) FindLocationByKey(key string) (*Location, error)
FindLocationByKey search the specified location in configured gitconfig file by key. Accepts the key to search as string as parameter It returns if found, the location information but also an error in case of any issue
func (LocationManager) GetLocations ¶
func (t LocationManager) GetLocations() ([]Location, error)
Get all configured locations in specified gitconfig file
func (LocationManager) SaveLocation ¶
func (t LocationManager) SaveLocation(key string, location string) error
Click to show internal directories.
Click to hide internal directories.