Fesh 0.20.0

dotnet add package Fesh --version 0.20.0                
NuGet\Install-Package Fesh -Version 0.20.0                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Fesh" Version="0.20.0" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Fesh --version 0.20.0                
#r "nuget: Fesh, 0.20.0"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Fesh as a Cake Addin
#addin nuget:?package=Fesh&version=0.20.0

// Install Fesh as a Cake Tool
#tool nuget:?package=Fesh&version=0.20.0                

Logo

Fesh

Fesh on nuget.org Build Hits code size license

Fesh is an F# Editor & Scripting Host.
On Windows.

It is designed for embedding F# as application scripting tool.
But it works standalone just as well.

Screenshot

It is based on the excellent AvalonEdit, that is why it only works on Windows (for now).
The editor supports F# 9.0 and has modern IDE features like semantic syntax highlighting, type-info and autocomplete.
Unlike a typical F# REPL this editor has the input and the output in two separate windows.
Just like Don Syme always wanted it.
You can even color the output with Fescher.

Contrary to most F# editors, it uses FSharp.Compiler.Service in the same process as the UI.
There is no separate language server or FSI process.
Therefore, Fesh can easily be hosted in other apps to create an embedded application scripting tool.
This was in fact the primary motivation for creating Fesh.
It is public since 2024.
But I started prototyping it in 2017. I used it for scripting in Rhino3D professionally since 2019.
Initially I used the Tsunami F# editor, like seen in my talk on the Louvre Abu Dhabi Dome.
But it is no longer available. So I created Fesh.

For hosting there is the nuget package Fesh. See hosting examples Fesh.Rhino and Fesh.Revit.

Features

Syntax Highlighting

Initial static syntax highlighting is done via AvalonEdit's regex based highlighting.
See SyntaxHighlightingFSharp.xshd.
The F# Compiler Service provides additional semantic highlighting.
If you want different colors go the menu: AboutOpen and watch SyntaxHighlighting in VS Code.
You wil see any changes upon every save in VS Code.

Auto complete

Auto complete works on enter and dot, also when typing in the middle of a word.

Type info

The type info includes the inferred signature.
All of the xml docs and information about the path of the containing assembly.

Status bar

The statusbar at the bottom shows compiler error count, click on it to scroll to the first error.

Selection highlighting

Selected text is highlighted in both code and output window. The count is shown in the status bar.

Drag and drop

Drag any file or folder into the editor to get the full path as a string at the cursor position.
For *.dlls it will be at the top and prefixed with #r.
For *.fsx it will be at the top and prefixed with #load.

Font

The default font is Cascadia Mono.
Besides italic it also supports a cursive script mode. Fesh is using cursive for comments.
To enable ligatures set the font to Cascadia Code.
You can change the font in the 'Settings.txt' file at %APPDATA%\Local\Fesh\Settings\Standalone\Settings.txt.
Or via the menu: AboutOpen Settings Folder.

How to install the Standalone App

Installer

The recommended way is to run the Setup.exe from Releases.
Fesh will automatically offer to update itself when a new version is available.
There is a .NET 9 and a .NET 4.8 version. Apart from the runtime they are the same.

The installer is created with Velopack and digitally signed.

No admin rights are required to install or run the app.
The app will be installed in \AppData\Local\Fesh.
A shortcut will be created on the desktop.

There is also a portable package in each release.
Extract that zip and place it wherever you'd like.
It has identical functionality to the installed app,
but keeps it's Settings folder in the same directory.
There is a ".portable" file in the folder to indicate that.
It will also automatically offer to update itself when a new version is available.

Build from source

Build from the source with:

dotnet build FeshStandalone.fsproj

You will still get notifications about new releases, but you have to install them manually.

How to host Fesh in another app

Use the nuget package Fesh.
Or, to build the Fesh nuget package run:

dotnet build FeshHosting.fsproj

Release Notes

For changes in each release see the CHANGELOG.md

License

Fesh is licensed under the MIT License.

Product Compatible and additional computed target framework versions.
.NET net7.0-windows7.0 is compatible.  net8.0-windows was computed.  net9.0-windows was computed. 
.NET Framework net472 is compatible.  net48 was computed.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
0.20.0 63 1/18/2025
0.19.0 92 1/12/2025
0.16.0 167 12/14/2024
0.15.0 95 11/22/2024
0.14.2 99 11/10/2024
0.14.1 101 11/7/2024
0.14.0 106 11/3/2024
0.13.0 136 10/19/2024
0.12.0 104 10/13/2024
0.11.1 91 10/6/2024
0.11.0 88 10/6/2024
0.10.0 111 8/26/2024
0.9.0 107 6/27/2024

### Changed

* - for portable version the location of SettingsFolder is inside the app folder now
* - update to latest FSharp.Compiler.Service
* - improved Readme and error messages