Documentation ¶
Overview ¶
package profilesutil provides utility routines for implementing profiles.
Index ¶
- Constants
- func AtomicAction(jirix *jiri.X, installFn func() error, dir, message string) error
- func Fetch(jirix *jiri.X, dst, url string) error
- func IsFNLHost() bool
- func MissingOSPackages(jirix *jiri.X, pkgs []string) ([]string, error)
- func OSPackageInstallCommands(jirix *jiri.X, pkgs []string) [][]string
- func Untar(jirix *jiri.X, srcFile, dstDir string) error
- func Unzip(jirix *jiri.X, srcFile, dstDir string) error
Constants ¶
const ( DefaultDirPerm = os.FileMode(0755) DefaultFilePerm = os.FileMode(0644) )
Variables ¶
This section is empty.
Functions ¶
func AtomicAction ¶
AtomicAction performs an action 'atomically' by keeping track of successfully completed actions in the supplied completion log and re-running them if they are not successfully logged therein after deleting the entire contents of the dir parameter. Consequently it does not make sense to apply AtomicAction to the same directory in sequence.
func IsFNLHost ¶
func IsFNLHost() bool
IsFNLHost returns true iff the host machine is running FNL TODO(bprosnitz) We should find a better way to detect that the machine is running FNL TODO(bprosnitz) This is needed in part because fnl is not currently a GOHOSTOS. This should probably be handled by having hosts that are separate from GOHOSTOSs similarly to how targets are defined.
func MissingOSPackages ¶
MissingOSPackages returns the subset of the supplied packages that are missing from the underlying operating system and hence will need to be installed.
func OSPackageInstallCommands ¶
OSPackagesInstallCommands returns the list of commands required to install the specified packages on the underlying operating system.
Types ¶
This section is empty.