18

I was hoping to upgrade to F# 3.0 but I can't find either a packaged F# 3.0 compiler on Microsoft site, nor if there is an express version to use. Is it possible to install F# 3.0 for use from the command line or a simple IDE and if so, how?

Muhammad Alkarouri
  • 23,884
  • 19
  • 66
  • 101

7 Answers7

15

The standalone version of F# is not available yet, but F# tools for Visual Studio Express have been released just 2 days ago, so you can get F# 3.0 for free.

As far as I know, there are definitely plans for open-source release (that can be integrated with MonoDevelop) and it would make sense to have a stand-alone installer too (otherwise you could still just compile the open-source release), but I don't think there are specific dates for that.

Tomas Petricek
  • 240,744
  • 19
  • 378
  • 553
  • For some reason I can't find F# Tools in the list of software provided by Web Installer 4.0 after I installed it. Is it really there? – Muhammad Alkarouri Sep 14 '12 at 13:52
  • 1
    If you follow the link in the blog and click 'Install', it immediately opens the installation of the F# tools (just tested it): http://www.microsoft.com/web/gallery/install.aspx?appid=FSharpVWD11 (but I suppose you need to install VS Express Web first to make the installer work). – Tomas Petricek Sep 14 '12 at 14:36
  • 1
    Direct download link: http://go.microsoft.com/fwlink/?LinkId=261286 Requires that .Net 4.5 be installed. – KevM Sep 05 '13 at 16:54
8

The easiest way I've got it to run: http://www.heartysoft.com/build-fsharp-3-on-build-server-without-vs

Essentially using the direct download link on the Web PI tools.

ashic
  • 6,367
  • 5
  • 33
  • 54
  • The direct-link (http://go.microsoft.com/fwlink/?LinkId=261286) you gave was really handy. For some reason, the Web PI tools is not showing me the F# installer at all. – Wallace Kelly Sep 03 '13 at 03:53
4

I have successfully make a standalone F# 3.0 works without Visual Studio 2012.

  1. First, find a workstation with F# 3.0 installed. (source)
  2. Duplicate all the things to destination workstation.
-> C:\Program Files (x86)\Microsoft SDKs\F#
-> C:\Program Files (x86)\Reference Assemblies\Microsoft\FSharp
-> C:\Windows\Microsoft.NET\assembly\GAC_MSIL\FSharp*
  1. Install .NET 4.5 at destination.
  2. Export all the registry item with FSC.exe string to destination.
  3. Export all the registry item with FSharp string to destination.

f# 3.0 registry.rar

if you don't know how to export the registry items, please download this file and use powershell to import all this .reg file.

PowerShell script: (put the .reg files into c:\xxx suppossedly )

cd c:\xxx
dir *.reg | %{ ('reg import "' + $_.Name + '"') | cmd }
Anibal Yeh
  • 349
  • 1
  • 11
  • If you bump into any trouble, please feel free to contact me at anibal.yeh@gmail.com – Anibal Yeh Feb 09 '13 at 13:17
  • +1 Thank you so much! These are great instructions for setting up a build server (and you do not want visual studio installed on it) – MattDavey Mar 12 '13 at 17:06
3

I'm assuming most of you seeking an answer to this question by now probably wouldn't mind the most recent version, which is 4.0. You can download this as a standalone at F# 4.0 . This does not include the supporting assemblies and will fail by itself. So you'll also have to download and install the Microsoft Build Tools 2015 . Should be all set to go from there, no installing the mega-massive visual studio. Of course if you need an IDE you'll need to seek out a free one.

1

You can use Nuget CLI to install the F# Compiler Tools without relying on Visual Studio. As a plus, this procedure does not require admin rights.

  1. Visit nuget.org/downloads and download the latest nuget.exe file.
  2. Instruct your browser to save the file to a folder of your choice.
  3. Add the folder where you placed nuget.exe to your PATH environment variable to use the CLI tool from anywhere.
  4. Open a command prompt and navigate to the folder where you want to install F# Tools.
  5. Run "nuget install FSharp.Compiler.Tools -Version {version}", where {version} is replaced with a version from https://www.nuget.org/packages/FSharp.Compiler.Tools
  6. Add the 'tools' directory to your PATH Environment Variable and then you will be able to use fsc and fsi from the command line.
0

There is not currently a standalone version of F# 3.0. However, one has been promised

John Palmer
  • 25,356
  • 3
  • 48
  • 67
  • 3
    Do you have a link for that promise? – svick Sep 14 '12 at 10:25
  • This would seem to imply it - The general release will be Friday at 10am PDT. The F# compiler will continue to be available as an independent installation, but that configuration is not part of this preview release. (from https://blogs.msdn.com/b/fsharpteam/archive/2011/09/14/f-3-0-developer-preview-now-available.aspx?Redirected=true) – John Palmer Sep 14 '12 at 10:35
  • would be nice to have a standalone ide for it – Nikos May 13 '15 at 10:16
0

I run F# 3.0 from the cygwin command line on Windows 7. You need to know a little about Linux/Unix to use cygwin, but the basics are not too difficult. You need the basic cygwin shell (command interpreter) and an editor. I am used to vi, so cygwin has vim (there exists a nice F# syntax color addon to vim).

You need to:

  1. Install visual studio in order to get F#
  2. in /users/myname/.bashrc add the location of Fsc.exe, which in my case is /cygdrive/c/Program Files (x86)/Microsoft SDKs/F#/3.0/Framework/v4.0 to your PATH.
DougT
  • 231
  • 1
  • 10