package fileutils

import "github.com/docker/docker/pkg/fileutils"

Index

Functions

func CopyFile

func CopyFile(src, dst string) (int64, error)

CopyFile copies from src to dst until either EOF is reached on src or an error occurs. It verifies src exists and removes the dst if it exists.

func CreateIfNotExists

func CreateIfNotExists(path string, isDir bool) error

CreateIfNotExists creates a file or a directory only if it does not already exist.

func ReadSymlinkedDirectory

func ReadSymlinkedDirectory(path string) (realPath string, err error)

ReadSymlinkedDirectory returns the target directory of a symlink. The target of the symbolic link may not be a file.

Source Files

fileutils.go

Version
v26.1.0+incompatible
Published
Apr 22, 2024
Platform
js/wasm
Imports
4 packages
Last checked
1 minute ago

Tools for package owners.