Skip to content

Instantly share code, notes, and snippets.

@mishazawa
Created December 7, 2019 14:25
Show Gist options
  • Select an option

  • Save mishazawa/9cf4e3641c19a6a122b0331636375f1d to your computer and use it in GitHub Desktop.

Select an option

Save mishazawa/9cf4e3641c19a6a122b0331636375f1d to your computer and use it in GitHub Desktop.
f# proj CLI

new project

dotnet new sln -o <NAME>

new lib file (module)

dotnet new classlib -lang F# -o src/<NAME>

new app file (entry point)

dotnet new console -lang F# -o src/<NAME>

add lib or app to project

dotnet sln add src/<PATH TO LIB>/<NAME>.fsproj

link lib to app

dotnet add src/<PATH A>/<NAME>.fsproj reference src/<PATH B>/<NAME>.fsproj

run

cd src/<PATH APP> && dotnet run <ARGS>

add deps NuGet

dotnet add src/<PATH TO LIB>/<NAME>.fsproj package <PACKAGE NAME>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment