Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CopyLinker ¶
type CopyLinker struct{}
CopyLinker deploys mods by copying files
func (*CopyLinker) Deploy ¶
func (l *CopyLinker) Deploy(src, dst string) error
Deploy copies src to dst
func (*CopyLinker) IsDeployed ¶
func (l *CopyLinker) IsDeployed(dst string) (bool, error)
IsDeployed checks if dst exists
func (*CopyLinker) Method ¶
func (l *CopyLinker) Method() domain.LinkMethod
Method returns the link method
func (*CopyLinker) Undeploy ¶
func (l *CopyLinker) Undeploy(dst string) error
Undeploy removes the file at dst
type HardlinkLinker ¶
type HardlinkLinker struct{}
HardlinkLinker deploys mods using hard links
func (*HardlinkLinker) Deploy ¶
func (l *HardlinkLinker) Deploy(src, dst string) error
Deploy creates a hard link from src to dst
func (*HardlinkLinker) IsDeployed ¶
func (l *HardlinkLinker) IsDeployed(dst string) (bool, error)
IsDeployed checks if dst exists (hardlinks are indistinguishable from regular files)
func (*HardlinkLinker) Method ¶
func (l *HardlinkLinker) Method() domain.LinkMethod
Method returns the link method
func (*HardlinkLinker) Undeploy ¶
func (l *HardlinkLinker) Undeploy(dst string) error
Undeploy removes the file at dst
type Linker ¶
type Linker interface {
Deploy(src, dst string) error
Undeploy(dst string) error
IsDeployed(dst string) (bool, error)
Method() domain.LinkMethod
}
Linker deploys and undeploys mod files to game directories
type SymlinkLinker ¶
type SymlinkLinker struct{}
SymlinkLinker deploys mods using symbolic links
func (*SymlinkLinker) Deploy ¶
func (l *SymlinkLinker) Deploy(src, dst string) error
Deploy creates a symlink from src to dst
func (*SymlinkLinker) IsDeployed ¶
func (l *SymlinkLinker) IsDeployed(dst string) (bool, error)
IsDeployed checks if dst is a symlink
func (*SymlinkLinker) Method ¶
func (l *SymlinkLinker) Method() domain.LinkMethod
Method returns the link method
func (*SymlinkLinker) Undeploy ¶
func (l *SymlinkLinker) Undeploy(dst string) error
Undeploy removes the symlink at dst