atomic-write-0.2.0.7: Atomically write to a file

Copyright© 2015-2019 Stack Builders Inc.
LicenseMIT
MaintainerStack Builders <hackage@stackbuilders.com>
Stabilityexperimental
Portabilityportable
Safe HaskellSafe
LanguageHaskell2010

System.AtomicWrite.Writer.String.Binary

Description

Provides functionality to dump the contents of a String to a file in binary mode.

Synopsis

Documentation

atomicWriteFile Source #

Arguments

:: FilePath

The path where the file will be updated or created

-> String

The content to write to the file

-> IO () 

Creates or modifies a file atomically on POSIX-compliant systems while preserving permissions.

atomicWithFile :: FilePath -> (Handle -> IO ()) -> IO () Source #

A general version of atomicWriteFile

atomicWriteFileWithMode Source #

Arguments

:: FileMode

The mode to set the file to

-> FilePath

The path where the file will be updated or created

-> String

The content to write to the file

-> IO () 

Creates or modifies a file atomically on POSIX-compliant systems and updates permissions