Documentation
¶
Overview ¶
Package safefs applies filesystem changes with dry-run support.
Index ¶
- func CheckSymlinks(root, srcDirRel, srcSkill string) error
- func SameFile(first, second string) bool
- type Applier
- func (a *Applier) Close() error
- func (a *Applier) CopyDir(src, dest, destRel string) error
- func (a *Applier) MkdirAll(destRel string, perm fs.FileMode) error
- func (a *Applier) RemoveAll(destRel string) error
- func (a *Applier) Within(destRel string) error
- func (a *Applier) WriteFile(destRel string, data []byte, perm fs.FileMode) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckSymlinks ¶
CheckSymlinks rejects symlinks escaping the source directory.
Types ¶
type Applier ¶
type Applier struct {
// contains filtered or unexported fields
}
Applier writes filesystem changes, honoring dry-run.
func NewApplier ¶
NewApplier creates an Applier bound to root.
Click to show internal directories.
Click to hide internal directories.