Note: This API documentation is for FAKE version 4. The migration API documentation can be found here. The API documentation for the new fake 5 modules can be found here

CscHelper

Contains tasks to compile C# source files with CSC.EXE (C# Compiler).

Nested types and modules

TypeDescription
CscParams

Compiler parameters

CscPlatform

Supported platforms

CscTarget

Supported output types

Functions and values

Function or valueDescription
csc setParams inputFiles
Signature: setParams:(CscParams -> CscParams) -> inputFiles:string list -> int

Compiles the given C# source files with the specified parameters.

Parameters

  • setParams - Function used to overwrite the default CSC parameters.
  • inputFiles - The C# input files.

Returns

The exit status code of the compile process.

Sample

1: 
2: 
3: 
4: 
5: 
["file1.cs"; "file2.cs"]
|> csc (fun parameters ->
         { parameters with Output = ...
                           Target = ...
                           ... })
Csc setParams inputFiles
Signature: setParams:(CscParams -> CscParams) -> inputFiles:string list -> unit

Compiles one or more C# source files with the specified parameters.

Parameters

  • setParams - Function used to overwrite the default CSC parameters.
  • inputFiles - The C# input files.

Sample

1: 
2: 
3: 
4: 
5: 
["file1.cs"; "file2.cs"]
|> Csc (fun parameters ->
              { parameters with Output = ...
                                Target = ...
                                ... })
cscExe toolPath srcFiles opts
Signature: toolPath:string -> srcFiles:string list -> opts:string list -> int