FAKE - F# Make - A DSL for build tasks and more FAKE
6.1.3

Lookig for older versions of the documentation, pre FAKE v6? See 

v5.fake.build

Directory Module

Contains helpers which allow to interact with the directory in file system.

Functions and values

Function or value Description

Directory.create

Full Usage: Directory.create

Returns: string -> unit

Creates a directory if it does not exist.

Returns: string -> unit

Directory.delete path

Full Usage: Directory.delete path

Parameters:
    path : string - The path to delete

Deletes a directory if it exists (including all contained elements).

path : string

The path to delete

Directory.ensure dir

Full Usage: Directory.ensure dir

Parameters:
    dir : string - The directory to check

Modifiers: inline

Checks if the given directory exists. If not then this functions creates the directory.

dir : string

The directory to check

Directory.findFirstMatchingFile pattern dir

Full Usage: Directory.findFirstMatchingFile pattern dir

Parameters:
    pattern : string - The glob pattern to use in matching
    dir : string - The directory to check

Returns: string

Gets the first file in the directory matching the search pattern or throws an error if nothing was found.

pattern : string

The glob pattern to use in matching

dir : string

The directory to check

Returns: string

Directory.tryFindFirstMatchingFile pattern dir

Full Usage: Directory.tryFindFirstMatchingFile pattern dir

Parameters:
    pattern : string - The glob pattern to use in matching
    dir : string - The directory to check

Returns: string option

Gets the first file in the directory matching the search pattern as an option value.

pattern : string

The glob pattern to use in matching

dir : string

The directory to check

Returns: string option