Rash thoughts about .NET, C#, F# and Dynamics NAV.

"Every solution will only lead to new problems."

Category FAKE – F# Make

Wednesday, 14. October 2015

Crazy stuff people do with FAKE and Paket – 1 of n

Filed under: .NET,C#,F#,FAKE - F# Make,Visual Studio — Steffen Forkmann at 11:33 Uhr

As many readers already know I’m maintaing the open source projects FAKE and Paket. These projects are used in many companies and open source projects to make continuous integration work on .NET and mono.

In this article series I want to highlight some of the more unsual use cases. Today I want to start and highlight the first 6 amazing projects.


FsReveal allows you to write beautiful slides in Markdown and brings C# and F# to the reveal.js web presentation framework.” [project site]

FsReveal uses Paket’s GitHub file dependencies feature to download reveal.js:

FsReveal GitHub references

It also uses a FAKE build script which converts Markdown files to html slides (via FSharp.Formatting) and runs these slides in a suave.io web server. FAKE’s file system watcher + suave’s socket implementation even allows you to edit your slides with automatic preview:



Stanford.NLP for .NET is a port of Stanford NLP distributions to .NET.

This project contains build scripts that recompile Stanford NLP .jar packages to .NET assemblies using IKVM.NET, tests that help to be sure that recompiled packages are workable and Stanford.NLP for .NET documentation site that hosts samples for all packages. All recompiled packages are available on NuGet.” [project site]

This project downloads .jar packages via Paket’s HTTP dependencies feature, recompiles everything to .NET via IKVM.NET in a FAKE build script and republishes it on NuGet. Automatic Java to .NET compilation – how cool is that?

Stanford NLP HTTP reference


“Manage your Paket dependencies from Visual Studio!” [project site]

Paket.VisualStudio is a VisualStudio addin that you can download from Microsoft’s VisualStudio gallery. Unfortunately even in 2015 Microsoft doesn’t provide an API for automating the upload to its gallery. Therefore Paket.VisualStudio uses Paket’s NuGet dependencies feature to download canopy and Selenium:


It then uses canopy + Selenium in a FAKE script to upload the addin via browser automation:

VS Gallery


“It’s part of Ionide plugin suite. F# IDE-like possibilities in Atom editor” [project site]

Ionide is an Atom plugin written in F#. It’s using Paket and FAKE to automate the build and release process.

First it uses FunScript to transpile F# to Javascript and then automates npm to resolve Javascript dependencies and apm to upload the plugin to the Atom gallery.


Akka.NET is a community-driven port of the popular Java/Scala framework Akka to .NET.” [project site]

Akka.Net is a big (mainly C#) open source project that uses FAKE and Paket. One interesting observation is that it needs to create different xUnit addins and therefore uses Paket’s groups feature to maintain the xUnit versions.



“The F# Data library implements everything you need to access data in your F# applications and scripts. It implements F# type providers for working with structured file formats (CSV, HTML, JSON and XML) and for accessing the WorldBank data. It also includes helpers for parsing CSV, HTML and JSON files and for sending HTTP requests.” [project site]

One of the many interesting things in FSharp.Data’s build is that it uses Paket to retrieve the FSharp.TypeProviders.StarterPack. These files need to be included in any F# type provider project and Paket allows you to manage this easily.


Tags: ,

Wednesday, 21. May 2014

Changes in the FAKE contribution workflow

Filed under: F#,FAKE - F# Make — Steffen Forkmann at 10:20 Uhr

Two months ago I started to use the RELEASE_NOTES.md files feature in FAKE to describe FAKE’s own changelog. It’s working pretty well with FSharp.Formatting and the whole process got much easier for me. One of the intersting side effects is that I didn’t use the develop branch any more. Pre-release packages can be pushed directly from master.

So in order to make it easier for new contributors I will follow standard git workflow and remove the develop branch completely. Please send your pull request directly to the master branch.

Monday, 31. March 2014

FAKE 2.12.0 released – NancyFx edition

Filed under: F#,FAKE - F# Make — Steffen Forkmann at 13:16 Uhr

FAKE logo

Today I released FAKE 2.12 with a lot of small bug fixes and improvements. The biggest feature is that we now use NancyFx for FAKE.Deploy. A big thanks to all of the 60 contributors.

What’s new?

  • Add getDependencies to NugetHelper #373
  • Add more F# friendly functions for IO.Path #374
  • SourceLink support #345
  • NancyFx instead of ASP.NET MVC for FAKE.Deploy #376 – big thanks to @MorganPersson
  • Allows to execute processes as unit tests #379
  • Allow to run MsTest test in isolation #367
  • Fixed Nuget.packSymbols #366
  • Fixed bug in SemVer parser #364
  • New title property in Nuspec parameters #359
  • Added option to disabled FAKE’s automatic process killing #357
  • Better AppyVeyor integration #353, #345
  • Added ability to define custom MSBuild loggers #352
  • Fix for getting the branch name with Git >= 1.9 #351
  • Added functions to write and delete from registry #350
  • NUnit NoThread, Domain and StopOnError parameters #349
  • Add support for VS2013 MSTest #346
  • Lots of small fixes

Getting started

If you new to FAKE you should read the getting started guide or clone the F# ProjectScaffold.

Go and grab the bits

Feel free to contact me if you need help for the upgrade.

Tags: ,

Tuesday, 14. January 2014

FSharpx.Collections 1.9 released

Filed under: .NET,C#,F#,FAKE - F# Make,Informatik — Steffen Forkmann at 11:29 Uhr

I’m happy to annouce the new release of the FSharpx.Collections package on nuget.

Most important changes:

Please tell me if it works for you.

Thursday, 7. March 2013

New tasks for building Xamarin Components in FAKE – F# Make

Filed under: F#,FAKE - F# Make — Steffen Forkmann at 12:50 Uhr

The current version of FAKE contains two tasks for Xamarins xpkg format. These are already used in Daniel Nauck’s Portable.Licensing project (read more about this project).

Sample usage:

Thank you Daniel for this contribution.

Tags: ,

Sunday, 27. January 2013

Released new AssemblyVersion tasks for FAKE

Filed under: C#,F#,FAKE - F# Make — Steffen Forkmann at 16:11 Uhr

Today I released two new AssemblyInfo tasks for FAKE and marked the old one as obsolete. One advantage of the new tasks is that they only generate the specified attributes and no more. There are already a lot of predefined attributes but it’s also possible to specify new ones. Here is a small example:

Tags: , ,

Saturday, 26. January 2013

Running FAKE targets from the command line

Filed under: F#,FAKE - F# Make — Steffen Forkmann at 12:47 Uhr

This post has been moved to http://fsharp.github.io/FAKE/commandline.html

Tags: ,

Wednesday, 9. January 2013

Using nuget package restore with “FAKE – F# Make” – Get rid of the binaries in your source code repository

Filed under: F#,FAKE - F# Make — Steffen Forkmann at 16:35 Uhr

This post has been moved to http://fsharp.github.io/FAKE/nuget.html

Tags: , ,

Monday, 16. January 2012

Building FAKE scripts with Jenkins

Filed under: F#,FAKE - F# Make — Steffen Forkmann at 16:11 Uhr

Jenkins is an extendable open source continuous integration server. In this blog post I show you how you can build FAKE’s Calculator sample with Jenkins. If you are familiar with Jenkins or Hudson then this should be straight forward.

Install Jenkins

Go to http://jenkins-ci.org/ and download/install Jenkins. In addition install the following plugins:

Create a new Task

Create a new “free-style” task in Jenkins:


Use git as the Source Control Management tool and configure the repo as following:


Configure the build step to run FAKE from the command line:


And finally configure the post build actions:


Running the build

If everything is setup correctly, then you should be able to start the build from the project page:


The output should look similar to this:


Tags: , , ,

Friday, 25. February 2011

Machine.Fakes released – Built with "FAKE – F# Make"

Filed under: F#,FAKE - F# Make,Tools — Steffen Forkmann at 14:09 Uhr

My friend Björn Rochel (@BjoernRochel) built a really cool generic model for using fakes and automocking on top of Machine.Specifications (or MSpec) called Machine.Fakes (or mfakes).

Today he released version (get it from nuget.org) and I want to talk a bit about the build process. Björn and myself thought a tool called “Machine.Fakes” should of course be built with a tool called “FAKE – F# Make”. In order to do so I had to fix some stuff in Fake which resulted in the new Fake version

Here are some things I fixed:

  • New task DeleteDirs allows to delete multiple directories.
  • New parameter for NuGet task which allows to specify dependencies.
  • Bundled with docu.exe compiled against .Net 4.0.
  • Fixed docu calls to run with full filenames.
  • Added targetplatform, target and log switches for ILMerge task.
  • Added Git.Information.getLastTag() which gets the last git tag by calling git describe.
  • Added Git.Information.getCurrentHash() which gets the last current sha1.
Machine.Fakes build setup

The build script for Machine.Fakes performs the following steps:

  1. It retrieves the version no. via GitHubs REST API
  2. It cleans all directories from old stuff
  3. It compiles the app and test projects
  4. It uses MSpec to test the application
  5. It merges StructureMap and StructureMap.AutoMocking into the app by using ILMerge
  6. It generates the XML documentation using the .NET 4.0 version of docu.exe
  7. It zips the app and the documentation files
  8. It builds and deploys a Nuget package with just Machine.Fakes
  9. It builds and deploys bundled Nuget packages in the following flavors:
    1. Machine.Fakes.FakeItEasy
    2. Machine.Fakes.RhinoMocks
    3. Machine.Fakes.Moq

Now you can start using this awesome project by calling:

install-package Machine.Fakes.{Flavor}

Tags: , , ,