File Operations

In addition to a rich set of standard file operations, the Wolfram Language's unified symbolic architecture makes it easy to apply algorithmic approaches and efficient higher-level programming to many file and system administration tasks.

ReferenceReference

FileNames list names of files or directories at any depth in the file system

CopyFile  ▪  RenameFile  ▪  DeleteFile

File Properties

FileDate  ▪  FileByteCount  ▪  SetFileDate  ▪  FileType  ▪  FileHash  ▪  FileFormat

File Utilities

FindList search for strings in lists of files

FilePrint display the raw contents of a file

ReadString get the complete contents of a file as a string

Directory Operations »

DirectoryQ test whether a name corresponds to an existing directory

CreateDirectory  ▪  CopyDirectory  ▪  DeleteDirectory  ▪  SetDirectory  ▪  ...

Finding Files

FindFile find a file on $Path etc.

FileNameSetter interactively browse for a file

FileExistsQ  ▪  AbsoluteFileName

File Name Operations »

FileNameSplit, FileNameJoin split, join file name strings

FileBaseName  ▪  DirectoryName  ▪  ExpandFileName  ▪  ...

Reading & Writing Files »

Import  ▪  Export  ▪  Get (<<)  ▪  Put (>>)  ▪  ReadList  ▪  BinaryReadList  ▪  ...

File Templates

FileTemplate set up a file as a template

TemplateApply apply a file template to specific data

Low-Level File Operations »

OpenRead  ▪  OpenWrite  ▪  Streams  ▪  Read  ▪  Skip  ▪  ...