anchor.diff:  /// Converts all line breaks in a text to windows line breaks
   let ConvertTextToWindowsLineBreaks text = 
       text
  -    |> replace WindowsLineBreaks LinuxLineBreaks 
  -    |> replace MacLineBreaks LinuxLineBreaks 
  +    |> replace WindowsLineBreaks LinuxLineBreaks
  +    |> replace MacLineBreaks LinuxLineBreaks
       |> replace LinuxLineBreaks WindowsLineBreaks
   
   /// Reads a file line by line and replaces all line breaks to windows line breaks
   ///   - uses a temp file to store the contents in order to prevent OutOfMemory exceptions
  -let ConvertFileToWindowsLineBreaks (fileName:string) = 
  +let ConvertFileToWindowsLineBreaks(fileName : string) = 
       use reader = new StreamReader(fileName, encoding)
  -
       let tempFileName = Path.GetTempFileName()
  -
  -    use writer = new StreamWriter(tempFileName,false,encoding) 
  -    
  +    use writer = new StreamWriter(tempFileName, false, encoding)
       while not reader.EndOfStream do
           reader.ReadLine()
           |> ConvertTextToWindowsLineBreaks
           |> writer.WriteLine
  -
       reader.Close()
       writer.Close()
  -
       File.Delete(fileName)
  -    File.Move(tempFileName,fileName)
  +    File.Move(tempFileName, fileName)
   
   /// Removes linebreaks from the given string
   let inline RemoveLineBreaks text = 
       text
  -      |> replace "\r" String.Empty
  -      |> replace "\n" String.Empty
  +    |> replace "\r" String.Empty
  +    |> replace "\n" String.Empty
   
   /// Encapsulates the Apostrophe
   let inline EncapsulateApostrophe text = replace "'" "`" text
  -        
  +
   /// A cache of relative path names.
   /// [omit]
  -let relativePaths = new Dictionary<_,_>()
  +let relativePaths = new Dictionary<_, _>()
   
   /// <summary>Produces relative path when possible to go from baseLocation to targetLocation.</summary>
   /// <param name="baseLocation">The root folder</param>
   /// <param name="targetLocation">The target folder</param>
   /// <returns>The relative path relative to baseLocation</returns>
   /// <exception cref="ArgumentNullException">base or target locations are null or empty</exception>
  -let ProduceRelativePath baseLocation targetLocation =
  -    if isNullOrEmpty baseLocation then
  -        raise (new ArgumentNullException "baseLocation")
  -    
  -    if isNullOrEmpty targetLocation then
  -        raise (new ArgumentNullException "targetLocation")
  -
  -    if not <| Path.IsPathRooted baseLocation then baseLocation else
  -    if not <| Path.IsPathRooted targetLocation then targetLocation else
  -    if String.Compare(Path.GetPathRoot baseLocation, Path.GetPathRoot targetLocation, true) <> 0 then targetLocation else
  -    if String.Compare(baseLocation, targetLocation, true) = 0 then "." else
  -    let resultPath = ref "."
  -
  -    let targetLocation =
  -        if targetLocation |> endsWith directorySeparator then targetLocation
  -        else targetLocation + directorySeparator
  -    
  -    let baseLocation =
  -        if baseLocation |> endsWith directorySeparator then
  -            ref (baseLocation.Substring(0, baseLocation.Length - 1))
  -        else 
  -            ref baseLocation
  -
  -    while not <| targetLocation.StartsWith(!baseLocation + directorySeparator, StringComparison.OrdinalIgnoreCase) do
  -        resultPath := !resultPath + directorySeparator + ".."
  -        baseLocation := Path.GetDirectoryName !baseLocation
  -
  -        if (!baseLocation) |> endsWith directorySeparator then
  -            baseLocation := (!baseLocation).Substring(0, (!baseLocation).Length - 1)
  -
  -    resultPath := 
  -        (!resultPath + targetLocation.Substring((!baseLocation).Length))
  -          |> replace (directorySeparator + directorySeparator) directorySeparator
  -
  -    // preprocess .\..\ case
  -    if (sprintf ".%s..%s" directorySeparator directorySeparator) <* (!resultPath) then
  -        (!resultPath).Substring(2, (!resultPath).Length - 3)
  -    else
  -        (!resultPath).Substring(0, (!resultPath).Length - 1)
  +let ProduceRelativePath baseLocation targetLocation = 
  +    if isNullOrEmpty baseLocation then raise (new ArgumentNullException "baseLocation")
  +    if isNullOrEmpty targetLocation then raise (new ArgumentNullException "targetLocation")
  +    if not <| Path.IsPathRooted baseLocation then baseLocation
  +    else if not <| Path.IsPathRooted targetLocation then targetLocation
  +    else if String.Compare(Path.GetPathRoot baseLocation, Path.GetPathRoot targetLocation, true) <> 0 then 
  +        targetLocation
  +    else if String.Compare(baseLocation, targetLocation, true) = 0 then "."
  +    else 
  +        let resultPath = ref "."
  +        
  +        let targetLocation = 
  +            if targetLocation |> endsWith directorySeparator then targetLocation
  +            else targetLocation + directorySeparator
  +        
  +        let baseLocation = 
  +            if baseLocation |> endsWith directorySeparator then ref (baseLocation.Substring(0, baseLocation.Length - 1))
  +            else ref baseLocation
  +        
  +        while not <| targetLocation.StartsWith(!baseLocation + directorySeparator, StringComparison.OrdinalIgnoreCase) do
  +            resultPath := !resultPath + directorySeparator + ".."
  +            baseLocation := Path.GetDirectoryName !baseLocation
  +            if (!baseLocation) |> endsWith directorySeparator then 
  +                baseLocation := (!baseLocation).Substring(0, (!baseLocation).Length - 1)
  +        resultPath 
  +        := (!resultPath + targetLocation.Substring((!baseLocation).Length)) 
  +           |> replace (directorySeparator + directorySeparator) directorySeparator
  +        // preprocess .\..\ case
  +        if (sprintf ".%s..%s" directorySeparator directorySeparator) <* (!resultPath) then 
  +            (!resultPath).Substring(2, (!resultPath).Length - 3)
  +        else (!resultPath).Substring(0, (!resultPath).Length - 1)
   
   /// Replaces the absolute path to a relative path.
   let inline toRelativePath value = 
       match relativePaths.TryGetValue value with
  -    | true,x -> x
  -    | _ ->
  -         let x = ProduceRelativePath currentDirectory value
  -         relativePaths.Add(value,x)
  -         x
  +    | true, x -> x
  +    | _ -> 
  +        let x = ProduceRelativePath currentDirectory value
  +        relativePaths.Add(value, x)
  +        x
   
   /// Find a regex pattern in a text and replaces it with the given replacement.
   let (>=>) pattern replacement text = regex_replace pattern replacement text
  
positive.code: let inline isNullOrWhiteSpace value = isNullOrEmpty value || value |> Seq.forall Char.IsWhiteSpace
  
  /// Replaces the given pattern in the given text with the replacement
  let inline replace (pattern:string) replacement (text:string) = text.Replace(pattern,replacement)
  
  /// Converts a sequence of strings to a string with delimiters
  let inline separated delimiter (items: string seq) = String.Join(delimiter, Array.ofSeq items)
  
  /// Removes the slashes from the end of the given string
  let inline trimSlash (s:string) = s.TrimEnd('\\')
  
  /// Splits the given string at the given char delimiter
  let inline split (delimiter:char) (text:string) = text.Split [|delimiter|] |> Array.toList
  
  /// Splits the given string at the given string delimiter
  let inline splitStr (delimiterStr:string) (text:string) = text.Split([|delimiterStr|], StringSplitOptions.None) |> Array.toList
  
  /// Converts a sequence of strings into a string separated with line ends
  let inline toLines text = separated Environment.NewLine text
  
  /// Checks whether the given text starts with the given prefix
  let startsWith prefix (text:string) = text.StartsWith prefix
  
  /// Checks whether the given text ends with the given suffix
  let endsWith suffix (text:string) = text.EndsWith suffix
  
  /// Determines whether the last character of the given <see cref="string" />
  /// matches Path.DirectorySeparatorChar.         
  let endsWithSlash = endsWith (Path.DirectorySeparatorChar.ToString())
  
  /// Replaces the first occurrence of the pattern with the given replacement.
  let replaceFirst (pattern: string) replacement (text: string) = 
      let pos = text.IndexOf pattern
      if pos < 0
          then text
          else text.Remove(pos, pattern.Length).Insert(pos, replacement)
          
  /// Appends a text to a StringBuilder.
  let inline append text (builder:StringBuilder) = builder.Append(sprintf "\"%s\" " text)
  
  /// Appends a text to a StringBuilder without surrounding quotes.
  let inline appendWithoutQuotes (text:string) (builder:StringBuilder) = builder.Append(text)
  
  /// Appends string of function value if option has some value
  let inline appendIfSome o f builder =
      match o with
      | Some(value) -> appendWithoutQuotes (f value) builder
      | None -> builder
  
  /// Appends a text if the predicate is true.
  let inline appendIfTrue p s builder = if p then append s builder else builder
  
  /// Appends a text if the predicate is false.
  let inline appendIfFalse p = appendIfTrue (not p)
  
  /// Appends a text if the value is not null.
  let inline appendIfNotNull (value : Object) s = 
      appendIfTrue (value <> null) (
          match value with 
          | :? String as sv -> (sprintf "%s%s" s sv)
          | _ -> (sprintf "%s%A" s value))
  
  /// Appends a quoted text if the value is not null.
  let inline appendQuotedIfNotNull (value : Object) s (builder:StringBuilder) =    
      if (value = null) then builder else (
          match value with 
          | :? String as sv -> builder.Append(sprintf "%s\"%s\" " s sv)
          | _ -> builder.Append(sprintf "%s\"%A\" " s value))
  
  /// Appends a text if the value is not null.
  let inline appendStringIfValueIsNotNull value = appendIfTrue (value <> null)
  
negative.code: let inline (<*) prefix text = startsWith prefix text
  
  /// Replaces the text in the given file
  let ReplaceInFile replaceF fileName = 
      fileName
      |> ReadFileAsString
      |> replaceF
  