filecopy

package
v1.1.14 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 26, 2025 License: MIT Imports: 9 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Copy added in v1.0.51

func Copy(srcDir string, targetDir string) error

func CopyFile added in v1.0.5

func CopyFile(src string, dst string) error

func CopyFileAll added in v1.0.5

func CopyFileAll(src string, dst string) error

CopyFileAll copy src to dst, creates dir if necessary

func CopyReplaceDir

func CopyReplaceDir(srcDir string, targetDir string, useLink bool) error

Replace the target dir with files copy

func LinkDirToTmp

func LinkDirToTmp(srcDir string, tmpDir string) (dstTmpDir string, err error)

func LinkFile

func LinkFile(srcFile string, dstFile string) error

func LinkFiles

func LinkFiles(srcDir string, targetDir string) error

NOTE: sym link must use abs path to ensure the file work correctly

Types

type Options added in v1.0.6

type Options struct {
	// contains filtered or unexported fields
}

func NewOptions added in v1.0.6

func NewOptions() *Options

func (*Options) Concurrent added in v1.0.6

func (c *Options) Concurrent(n int) *Options

func (*Options) Copy added in v1.0.51

func (c *Options) Copy(srcDir string, targetDir string) error

func (*Options) CopyReplaceDir added in v1.0.6

func (c *Options) CopyReplaceDir(srcDir string, targetDir string) error

func (*Options) Ignore added in v1.0.26

func (c *Options) Ignore(subPath ...string) *Options

func (*Options) IgnoreSuffix added in v1.0.26

func (c *Options) IgnoreSuffix(suffix ...string) *Options

func (*Options) IncludeSuffix added in v1.0.26

func (c *Options) IncludeSuffix(suffix ...string) *Options
func (c *Options) UseLink() *Options

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL