profile

package
v0.0.0-...-44808bf Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2020 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Overview

Package profile handles profiled settings.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Profile

type Profile struct {
	Name       string
	Home       string
	Config     string
	ConfigFile string
	Run        string
}

Profile holds the profile settings.

func New

func New() *Profile

New creates a new object with defaults values set.

func (*Profile) GetConfigFile

func (p *Profile) GetConfigFile() string

GetConfigFile returns the absolute filename of the configuration file for the current os user. This is the filename used to save configuration updates.

func (*Profile) GetPath

func (p *Profile) GetPath(name string) string

GetPath returns the absolute profile named filepath.

func (*Profile) GetRundir

func (p *Profile) GetRundir() string

GetRundir returns the profile named rundir path.

func (*Profile) GetRundirPath

func (p *Profile) GetRundirPath(name string) string

GetRundirPath returns an absolute rundir profile named filepath.

func (*Profile) ListConfigFiles

func (p *Profile) ListConfigFiles() []string

ListConfigFiles returns a list of all the profiled filenames to read the configuration from.

func (*Profile) Setup

func (p *Profile) Setup() error

Setup checks runtime setup requirements.

func (*Profile) String

func (p *Profile) String() string

String returns profile base path. But just for info/debug purposes. It will always be slash (/) separated.

Jump to

Keyboard shortcuts

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