Open adam-c-anderson opened 2 years ago
Welcome to the FAKE community! Thank you so much for creating your first issue and therefore improving the project!
in the interim, you can #load
the .fake/<build script name>/intellisense.fsx
manually to get intellisense, the FAKE extension in Ionide just looked this up by convention (plus a couple other UX helpers).
Thanks for the tip. I am already doing that, but still get intellisense errors everywhere.
I think, at least in part, because of this MiniScaffold, and other community projects have moved to using a build.fsproj and simply referencing and calling fake. @adam-c-anderson
I had a similar problem when cleaning everything for a NetCore50 update. You need to at least do a first build before the intellisense can work.
mkdir tst
cd tst
dotnet new -i fake-template
dotnet new fake
code .
Other thing the template misses is ignoring the #r
directive, its doesn't work with Ionide
, but that's no problem as long as you do the following, it will work.
fake -v build --list
build.fsx
#if FAKE
#r "paket:
nuget Fake.DotNet.Cli
nuget Fake.IO.FileSystem
nuget Fake.Core.Target //"
#endif
#load ".fake/build.fsx/intellisense.fsx"
open Fake.Core
open Fake.DotNet
open Fake.IO
open Fake.IO.FileSystemOperators
open Fake.IO.Globbing.Operators
open Fake.Core.TargetOperators
//rest.....
This chicken and egg problem is kinda funny, fake
needs paket
, paket
needs fake
, ionide
needs both, and the Fsharp language services, aka FCS
, which is incompatible with the former tools need just the assembly list.
Things are a bit better if you use dotnet tool
, or chocolatey
to set up those 2 tools. It is what it is, C#
doesn't suffer that badly from it I guess, its bootstrapped already from dotnet
with everything it needs.
Microsoft really should upstream both Fake
and Paket
as de-facto F# build environment.
The issue reported here is still in effect. It seems the solution is known, but it hasn't been implemented in the 9 months since it was reported. Will it be in the 5.21 release?