file

package
v4.0.0-pre-2 Latest Latest
Warning

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

Go to latest
Published: Jan 23, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package file contains functions for working with files and directories on the local filesystem

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Read deprecated

func Read(filename string) (string, error)

Read the contents of the referenced file, as a string.

Deprecated: (as of 4.0.0) use [io/fs#ReadFile] instead

func ReadDir deprecated

func ReadDir(path string) ([]string, error)

ReadDir gets a directory listing.

Deprecated: (as of 4.0.0) use [io/fs#ReadDir] instead

func Write deprecated

func Write(filename string, content []byte) error

Write the given content to the file, truncating any existing file, and creating the directory structure leading up to it if necessary.

Deprecated: (as of 4.0.0) use [os#WriteFile] instead

Types

This section is empty.

Jump to

Keyboard shortcuts

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