pathing

package
v1.6.6 Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2020 License: MPL-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConfigDir

func ConfigDir() (string, error)

ConfigDir returns the configuration directory for Packer.

func ConfigFile

func ConfigFile() (string, error)

ConfigFile returns the default path to the configuration file. On Unix-like systems this is the ".packerconfig" file in the home directory. On Windows, this is the "packer.config" file in the application data directory.

func ExpandUser

func ExpandUser(path string) (string, error)

Given a path, check to see if it's using ~ to reference a user directory. If so, then replace that component with the requested user directory. In "~/", "~" gets replaced by current user's home dir. In "~root/", "~user" gets replaced by root's home dir. ~ has to be the first character of path for ExpandUser change it.

Types

This section is empty.

Jump to

Keyboard shortcuts

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