Documentation ¶
Index ¶
- func RunToolbx(options ...ToolbxOption) error
- type ToolbxOption
- func WithBrandLabel(brand string) ToolbxOption
- func WithCommandsRepository(repo string, branch string) ToolbxOption
- func WithConfigFile(path string) ToolbxOption
- func WithDataDir(dataDir string) ToolbxOption
- func WithGitlab(personalAccessToken string) ToolbxOption
- func WithXdg(name string) ToolbxOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RunToolbx ¶
func RunToolbx(options ...ToolbxOption) error
Types ¶
type ToolbxOption ¶
type ToolbxOption func(cfg *config.Configuration)
func WithBrandLabel ¶
func WithBrandLabel(brand string) ToolbxOption
func WithCommandsRepository ¶
func WithCommandsRepository(repo string, branch string) ToolbxOption
func WithConfigFile ¶
func WithConfigFile(path string) ToolbxOption
WithConfigFile ensure the configuration will be loaded from path. Path need to contain also YAML file.
func WithDataDir ¶
func WithDataDir(dataDir string) ToolbxOption
WithDataDir set data directory, where are placed installations etc...
func WithGitlab ¶
func WithGitlab(personalAccessToken string) ToolbxOption
If you want to use GitLab for distribution, you need to provide GitLab token
func WithXdg ¶
func WithXdg(name string) ToolbxOption
WithXdg ensure the toolbx will use XDG directory spec. for config files and all data files.
The data will be stored in $HOME/.local/share/{name} and configuration will be loaded from $HOME/.config/{name}/{name}.yaml
Click to show internal directories.
Click to hide internal directories.