fileutil

package
v1.106.5 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2023 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FileExists

func FileExists(filename string) (bool, error)

File exists has three different return cases that should be handled:

  1. File exists and is not a directory (true, nil)
  2. File does not exist (false, nil)
  3. File may or may not exist. Error occurred during stat (false, error)

The third case represents the scenario where the stat returns an error, but the error isn't relevant to the path. This can happen when the current user doesn't have permission to access the file.

Types

This section is empty.

Jump to

Keyboard shortcuts

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