Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependencies metadata #204

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions Fable.REPL.sln
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ VisualStudioVersion = 15.0.26124.0
MinimumVisualStudioVersion = 15.0.26124.0
Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "App", "src\App\App.fsproj", "{39F5D300-0762-421C-ACF3-6E4509E44D78}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{E3285035-697D-49AA-8A30-95E349A4EBDF}"
EndProject
Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "fcs-export", "src\Export\fcs-export.fsproj", "{76A81454-3826-493A-9F19-9D0CE5C6C54E}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand All @@ -30,5 +34,20 @@ Global
{39F5D300-0762-421C-ACF3-6E4509E44D78}.Release|x64.Build.0 = Release|Any CPU
{39F5D300-0762-421C-ACF3-6E4509E44D78}.Release|x86.ActiveCfg = Release|Any CPU
{39F5D300-0762-421C-ACF3-6E4509E44D78}.Release|x86.Build.0 = Release|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Debug|x64.ActiveCfg = Debug|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Debug|x64.Build.0 = Debug|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Debug|x86.ActiveCfg = Debug|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Debug|x86.Build.0 = Debug|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Release|Any CPU.Build.0 = Release|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Release|x64.ActiveCfg = Release|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Release|x64.Build.0 = Release|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Release|x86.ActiveCfg = Release|Any CPU
{76A81454-3826-493A-9F19-9D0CE5C6C54E}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{76A81454-3826-493A-9F19-9D0CE5C6C54E} = {E3285035-697D-49AA-8A30-95E349A4EBDF}
EndGlobalSection
EndGlobal
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"sdk": {
"version": "6.0.100",
"version": "8.0.100",
"rollForward": "minor"
}
}
10 changes: 5 additions & 5 deletions paket.dependencies
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ storage:none
framework: netstandard2.0

nuget FSharp.Core
nuget Fable.Core
nuget Fable.Core 4.3
nuget Fable.Elmish.Browser
nuget Fable.React
nuget Fable.Elmish
Expand All @@ -13,14 +13,14 @@ nuget Thoth.Json
nuget Thoth.Elmish.Toast
nuget Fable.Fetch
nuget Fable.FontAwesome.Free
nuget Feliz prerelease
nuget Feliz
nuget Feliz.Bulma
nuget Feliz.Bulma.Tooltip
nuget Fable.Browser.Css
nuget Fable.Browser.Dom == 2.4.4
nuget Fable.Browser.Event == 1.4.5
nuget Fable.Browser.Dom
nuget Fable.Browser.Event
nuget Fable.Browser.MediaQueryList
nuget Fable.Browser.Navigator == 2.0.0
nuget Fable.Browser.Navigator

# REPL Lib

Expand Down
144 changes: 74 additions & 70 deletions paket.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,68 +2,72 @@ STORAGE: NONE
RESTRICTION: == netstandard2.0
NUGET
remote: https://www.nuget.org/api/v2
Fable.AST (4.2.1)
Fable.Browser.Blob (1.3)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Browser.Css (2.3)
Fable.Browser.Dom (>= 2.11)
Fable.Browser.Svg (>= 2.3)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Browser.Dom (2.4.4)
Fable.Browser.Blob (>= 1.1.4)
Fable.Browser.Event (>= 1.4.4)
Fable.Browser.WebStorage (>= 1.0.4)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Browser.Event (1.4.5)
Fable.Browser.Gamepad (>= 1.0.3)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Browser.Gamepad (1.2)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Browser.Geolocation (1.2)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Browser.MediaQueryList (1.4)
Fable.Browser.Dom (>= 2.11)
Fable.Browser.Event (>= 1.5)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Browser.MediaStream (3.3)
Fable.Browser.Dom (>= 2.11)
Fable.Browser.Event (>= 1.5)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Browser.Navigator (2.0)
Fable.Browser.Gamepad (>= 1.0.3)
Fable.Browser.Geolocation (>= 1.0.4)
Fable.Browser.MediaStream (>= 3.0.4)
Fable.Browser.Worker (>= 1.0.5)
Fable.Core (>= 3.1.5)
FSharp.Core (>= 4.7.2)
Fable.Browser.Svg (2.3)
Fable.Browser.Dom (>= 2.11)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Browser.WebStorage (1.2)
Fable.Browser.Event (>= 1.5)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Browser.Worker (1.2)
Fable.Browser.Event (>= 1.5)
Fable.Core (>= 3.0)
FSharp.Core (>= 4.7.2)
Fable.Core (4.0)
Fable.Elmish (4.0.2)
Fable.AST (4.5)
Fable.Browser.Blob (1.4)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.Css (2.5)
Fable.Browser.Dom (>= 2.16)
Fable.Browser.Svg (>= 2.4)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.Dom (2.18)
Fable.Browser.Blob (>= 1.4)
Fable.Browser.Event (>= 1.7)
Fable.Browser.WebStorage (>= 1.3)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.Event (1.7)
Fable.Browser.Gamepad (>= 1.3)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.Gamepad (1.3)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.Geolocation (1.3)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.MediaQueryList (1.5)
Fable.Browser.Dom (>= 2.16)
Fable.Browser.Event (>= 1.6)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.MediaStream (3.4)
Fable.Browser.Dom (>= 2.16)
Fable.Browser.Event (>= 1.6)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.Navigator (2.5)
Fable.Browser.Gamepad (>= 1.3)
Fable.Browser.Geolocation (>= 1.3)
Fable.Browser.MediaStream (>= 3.3)
Fable.Browser.Worker (>= 1.3)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.Svg (2.4)
Fable.Browser.Dom (>= 2.16)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.Url (1.4)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.WebStorage (1.3)
Fable.Browser.Event (>= 1.6)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Browser.Worker (1.4)
Fable.Browser.Event (>= 1.6)
Fable.Browser.Url (>= 1.4)
Fable.Core (>= 3.2.8)
FSharp.Core (>= 4.7.2)
Fable.Core (4.3)
Fable.Elmish (4.2)
Fable.Core (>= 3.7.1)
FSharp.Core (>= 4.7.2)
Fable.Elmish.Browser (4.0.1)
Fable.Browser.Dom (>= 2.10.1)
Fable.Elmish (>= 4.0)
Fable.Elmish.UrlParser (>= 1.0.1)
Fable.Elmish.Browser (4.0.3)
Fable.Browser.Dom (>= 2.14)
Fable.Elmish (>= 4.1)
Fable.Elmish.UrlParser (>= 1.0.2)
FSharp.Core (>= 4.7.2)
Fable.Elmish.HMR (7.0)
Fable.Core (>= 3.7.1)
Expand All @@ -73,9 +77,9 @@ NUGET
Fable.Elmish (>= 4.0)
Fable.ReactDom.Types (>= 18.0)
FSharp.Core (>= 4.7.2)
Fable.Elmish.UrlParser (1.0.1)
Fable.Elmish.UrlParser (1.0.2)
FSharp.Core (>= 4.7.2)
Fable.Fetch (2.6)
Fable.Fetch (2.7)
Fable.Browser.Blob (>= 1.2)
Fable.Browser.Event (>= 1.5)
Fable.Core (>= 3.7.1)
Expand All @@ -91,7 +95,7 @@ NUGET
Fable.Promise (3.2)
Fable.Core (>= 3.7.1)
FSharp.Core (>= 4.7.2)
Fable.React (9.3)
Fable.React (9.4)
Fable.React.Types (>= 18.3)
Fable.ReactDom.Types (>= 18.2)
FSharp.Core (>= 4.7.2)
Expand All @@ -102,7 +106,7 @@ NUGET
Fable.ReactDom.Types (18.2)
Fable.React.Types (>= 18.3)
FSharp.Core (>= 4.7.2)
Feliz (2.6)
Feliz (2.8)
Fable.ReactDom.Types (>= 18.2)
Feliz.CompilerPlugins (>= 2.2)
FSharp.Core (>= 4.7.2)
Expand All @@ -121,14 +125,14 @@ NUGET
FsCheck.NUnit (2.16.6)
FsCheck (2.16.6)
NUnit (>= 3.13.1 < 4.0)
FSharp.Core (7.0.300)
Microsoft.NET.Test.Sdk (17.7)
FSharp.Core (8.0.401)
Microsoft.NET.Test.Sdk (17.11.1)
Microsoft.NETCore.Platforms (7.0.4)
NETStandard.Library (2.0.3)
Microsoft.NETCore.Platforms (>= 1.1)
NUnit (3.13.3)
NUnit (3.14)
NETStandard.Library (>= 2.0)
NUnit3TestAdapter (4.5)
NUnit3TestAdapter (4.6)
SourceLink.Create.CommandLine (2.8.3)
Thoth.Elmish.Toast (4.0)
Fable.Core (>= 3.7.1)
Expand All @@ -139,8 +143,8 @@ NUGET
Thoth.Json (10.2)
Fable.Core (>= 3.6.2)
FSharp.Core (>= 4.7.2)
Unquote (6.1)
FSharp.Core (>= 4.7.2)
Unquote (7.0)
FSharp.Core (>= 8.0.100)
GITHUB
remote: elmish/elmish
FULLPROJECT (8354fe939afe8a5de633586915c7da31b29e162a)
Expand Down
55 changes: 31 additions & 24 deletions src/Export/Program.fs
Original file line number Diff line number Diff line change
@@ -1,35 +1,42 @@
open System.IO
open System.Collections.Generic
open FSharp.Compiler.CodeAnalysis
open Ionide.ProjInfo

let readRefs (folder : string) (projectFile: string) =
let runProcess (workingDir: string) (exePath: string) (args: string) =
let psi = System.Diagnostics.ProcessStartInfo()
psi.FileName <- exePath
psi.WorkingDirectory <- workingDir
psi.RedirectStandardOutput <- false
psi.RedirectStandardError <- false
psi.Arguments <- args
psi.CreateNoWindow <- true
psi.UseShellExecute <- false
let projectDirectory: DirectoryInfo = DirectoryInfo folder
let fsProjPath = __SOURCE_DIRECTORY__ + "/" + projectFile
let toolsPath = Init.init projectDirectory None
let defaultLoader: IWorkspaceLoader = WorkspaceLoader.Create(toolsPath, [])

use p = new System.Diagnostics.Process()
p.StartInfo <- psi
p.Start() |> ignore
p.WaitForExit()
let mutable isReady = false
let mutable refs = []

let exitCode = p.ExitCode
exitCode, ()
let subscription: System.IDisposable = defaultLoader.Notifications.Subscribe(fun msg ->
match msg with
| Types.WorkspaceProjectState.Loaded (proj, _, _) ->
printfn "Project loaded"

let runCmd exePath args = runProcess folder exePath (args |> String.concat " ")
let msbuildExec = Dotnet.ProjInfo.Inspect.dotnetMsbuild runCmd
let result = Dotnet.ProjInfo.Inspect.getProjectInfo ignore msbuildExec Dotnet.ProjInfo.Inspect.getFscArgs projectFile
match result with
| Ok(Dotnet.ProjInfo.Inspect.GetResult.FscArgs x) ->
x
|> List.filter (fun s -> s.StartsWith("-r:"))
|> List.map (fun s -> s.Replace("-r:", ""))
| _ -> []
refs <-
proj.OtherOptions
|> List.filter (fun s -> s.StartsWith("-r:"))
|> List.map (fun s -> s.Replace("-r:", ""))
isReady <- true

| Types.WorkspaceProjectState.Failed (projectFilePath, errors) ->
printfn "Errors: %A" errors
failwithf "Failed to load project: %s" projectFilePath
| Types.WorkspaceProjectState.Loading (projectFilePath) ->
printfn "Loading project: %s" projectFilePath
)

let projectOptions = defaultLoader.LoadProjects([ fsProjPath ]) |> Seq.toArray

// This is ugly, but I don't know how to transform an Observable to Async or Syncronous operation
while not isReady do
System.Threading.Thread.Sleep(100)

refs

let mkStandardProjectReferences () =
let file = "fcs-export.fsproj"
Expand Down
8 changes: 6 additions & 2 deletions src/Export/build.sh
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,17 +1,21 @@
#!/bin/bash

# This expects to be run from repo root dir and have ncave's F# compiler fork
# and Fable repos in sibling folders

NCAVE_FSHARP_REPO=fsharp_fable
REPL_REPO=repl

set -x # Output commands as they're executed
set -e # Stop on first error
set -o noglob # Disable globbing

dotnet build src/Fable.Repl.Lib

cd ../$NCAVE_FSHARP_REPO
git checkout export
dotnet build -c Release src/buildtools/buildtools.proj
dotnet build -c Release src/fsharp/FSharp.Compiler.Service
dotnet build -c Release buildtools/buildtools.proj
dotnet build -c Release src/Compiler/FSharp.Compiler.Service.fsproj

cd ../$REPL_REPO
dotnet run -c Release -p src/Export
Expand Down
6 changes: 3 additions & 3 deletions src/Export/fcs-export.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
</PropertyGroup>

Expand All @@ -18,8 +18,8 @@

<ItemGroup>
<!-- <PackageReference Include="FSharp.Core" Version="5.0.1" /> -->
<PackageReference Include="Fable.Core" Version="3.2.6" />
<PackageReference Include="Dotnet.ProjInfo" Version="0.44.0" />
<PackageReference Include="Fable.Core" Version="4.3.0" />
<PackageReference Include="Ionide.ProjInfo" Version="0.67.0" />
<PackageReference Include="Fable.Browser.Css" Version="2.*" />
<PackageReference Include="Fable.Browser.Dom" Version="2.*" />
<PackageReference Include="Fable.Browser.MediaQueryList" Version="1.*" />
Expand Down
4 changes: 2 additions & 2 deletions src/Fable.Repl.Lib/Sutil/Sutil.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
<Compile Include="Bulma.fs" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Feliz.Engine.Bulma" Version="1.0.0-beta-005" />
<PackageReference Include="Feliz.Engine" Version="1.0.0-beta-004" />
<!-- <PackageReference Include="Feliz.Engine.Bulma" Version="1.0.0-beta-005" />
<PackageReference Include="Feliz.Engine" Version="1.0.0-beta-004" /> -->
<PackageReference Include="Fable.Browser.Css" Version="2.*" />
<PackageReference Include="Fable.Browser.Dom" Version="2.*" />
<PackageReference Include="Fable.Browser.Event" Version="1.*" />
Expand Down