xdg

package module
v0.0.0-...-38518e0 Latest Latest
Warning

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

Go to latest
Published: May 18, 2015 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package xdg provides functions for finding configuration files using the XDG Base Directory Standard.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Config

func Config(name string) string

Config finds the configuration file with the given name. It returns a path only if a file exists at that path; if all search directories are exhausted then the empty string is returned.

func ConfigDirs

func ConfigDirs() []string

ConfigDirs returns a ordered list of directories to search for configuration files in. It is defined by the environment variable $XDG_CONFIG_DIRS, but if this is not present defaults to /etc/xdg.

func ConfigHome

func ConfigHome() string

ConfigHome returns the directory configuration files should be stored in, this directory has higher precendence than those given by ConfigDirs. It is defined by the environment variable $XDG_CONFIG_HOME, but if this is not present defaults to $HOME/.config.

Types

This section is empty.

Jump to

Keyboard shortcuts

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