Documentation
¶
Overview ¶
Package system provides ergonomic wrappers for operating system APIs.
Index ¶
- func Copy(dst io.Writer, src io.Reader) (int64, error)
- func CopyN(dst io.Writer, src io.Reader, n int64) (written int64, err error)
- func Lclearxattrs(path string, skipFn func(xattrName string) bool) error
- func Lgetxattr(path string, name string) ([]byte, error)
- func Llistxattr(path string) ([]string, error)
- func Lutimes(path string, atime, mtime time.Time) error
- func Mknod(path string, mode uint32, dev uint64) error
- func Tarmode(typeflag byte) uint32
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Copy ¶
Copy has identical semantics to io.Copy except it will automatically resume the copy after it receives an EINTR error.
func CopyN ¶
CopyN has identical semantics to io.CopyN except it will automatically resume the copy after it receives an EINTR error.
func Lclearxattrs ¶
Lclearxattrs is a wrapper around Llistxattr and Lremovexattr, which attempts to remove all xattrs from a given file.
If skipFn is non-nil and returns true when passed an xattr we planned to remove, that xattr is skipped and remains set on the path.
func Lgetxattr ¶
Lgetxattr is a wrapper around unix.Lgetattr, to abstract the resizing of the returned []string.
func Llistxattr ¶
Llistxattr is a wrapper around unix.Llistattr, to abstract the NUL-splitting and resizing of the returned []string.
func Lutimes ¶
Lutimes is a wrapper around utimensat(2), with the AT_SYMLINK_NOFOLLOW flag set, to allow changing the time of a symlink rather than the file it points to.
Types ¶
This section is empty.