Versions in this module Expand all Collapse all v0 v0.1.0 Jan 18, 2025 Changes in this version + const BlockSize + func CopyDir(from, to string) error + func CreateRandomDir(path, prefix string) (string, error) + func CreateRandomFileName(path, prefix string) (string, error) + func EnsureDirExists(dir string) error + func EnsureFileExists(fn string) error + func GetRoot(path string) (string, string) + func HashDir(path string, testFunc func(fi os.FileInfo) bool, recursive bool) (strutil.Hash, error) + func IsDirEmpty(name string) (bool, error) + func ListDir(dir string) []os.FileInfo + func RemoveFiles(path string, testFunc func(path string, fi os.FileInfo) bool) error + func UnzipToFolder(zipFile, destDir string) error + func WriteTo(toPath string, in io.Reader) error + func ZipCopy(zw *ZipWriter, zi ZipIterator, prefix string) error + func ZipFolder(srcDir, destFile string, testFunc func(string) bool, recursive bool) error + type MMFile struct + func NewMMFile(fname string, minSize int64) (*MMFile, error) + func (mmf *MMFile) Buffer(offs int64, size int) ([]byte, error) + func (mmf *MMFile) Close() error + func (mmf *MMFile) Flush() error + func (mmf *MMFile) Grow(newSize int64) (err error) + func (mmf *MMFile) Size() int64 + func (mmf *MMFile) String() string + type ZipIterator interface + Next func() *zip.File + func NewZipIterator(zipFile string) (ZipIterator, error) + type ZipWriter struct + func NewZipWriter(zipFilename string) (*ZipWriter, error) + func (zw *ZipWriter) Close() error + func (zw *ZipWriter) Create(fileName string) (io.Writer, error)