# 1.0.0[−][src]Module std::fs

Filesystem manipulation operations.

This module contains basic methods to manipulate the contents of the local filesystem. All methods in this module represent cross-platform filesystem operations. Extra platform-specific functionality can be found in the extension traits of `std::os::$platform`.

## Structs

DirBuilder | A builder used to create directories in various manners.
DirEntry | Entries returned by the `ReadDir` iterator.
File | A reference to an open file on the filesystem.
FileType | A structure representing a type of file with accessors for each file type. It is returned by `Metadata::file_type` method.
Metadata | Metadata information about a file.
OpenOptions | Options and flags which can be used to configure how a file is opened.
Permissions | Representation of the various permissions on a file.
ReadDir | Iterator over the entries in a directory.

## Functions

canonicalize | Returns the canonical, absolute form of a path with all intermediate components normalized and symbolic links resolved.
copy | Copies the contents of one file to another. This function will also copy the permission bits of the original file to the destination file.
create_dir | Creates a new, empty directory at the provided path
create_dir_all | Recursively create a directory and all of its parent components if they are missing.
hard_link | Creates a new hard link on the filesystem.
metadata | Given a path, query the file system to get information about a file, directory, etc.
read | Read the entire contents of a file into a bytes vector.
read_dir | Returns an iterator over the entries within a directory.
read_link | Reads a symbolic link, returning the file that the link points to.
read_to_string | Read the entire contents of a file into a string.
remove_dir | Removes an existing, empty directory.
remove_dir_all | Removes a directory at this path, after removing all its contents. Use carefully!
remove_file | Removes a file from the filesystem.
rename | Rename a file or directory to a new name, replacing the original file if `to` already exists.
set_permissions | Changes the permissions found on a file or a directory.
soft_link | [ Deprecated ] Creates a new symbolic link on the filesystem.
symlink_metadata | Query the metadata about a file without following symlinks.
write | Write a slice as the entire contents of a file.

# Help

## Keyboard Shortcuts

`?`
  Show this help dialog
`S`
  Focus the search field
`↑`
  Move up in search results
`↓`
  Move down in search results
`↹`
  Switch tab
`⏎`
  Go to active search result
`+`
  Expand all sections
`-`
  Collapse all sections

## Search Tricks

Prefix searches with a type followed by a colon (e.g., `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct`, `enum`, `trait`, `type`, `macro`, and `const`.

Search functions by type signature (e.g., `vec -> usize` or `* -> vec`)

Search multiple things at once by splitting your query with comma (e.g., `str,u8` or `String,struct:Vec,test`)