Skip to content

Commit

Permalink
Merge branch 'master' into quotations
Browse files Browse the repository at this point in the history
  • Loading branch information
alfonsogarciacaro committed Jun 4, 2020
2 parents d5227d6 + 5fd5c47 commit a48d4bf
Show file tree
Hide file tree
Showing 137 changed files with 3,313 additions and 2,108 deletions.
21 changes: 11 additions & 10 deletions .docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
FROM gitpod/workspace-full:latest

USER root

# Add here the instruction who needs root user


USER gitpod

# Install dotnet core
ENV PATH=$HOME/.dotnet:$PATH
RUN wget https://dotnetwebsite.azurewebsites.net/download/dotnet-core/scripts/v1/dotnet-install.sh && \
bash dotnet-install.sh -v 3.1.201 && \
rm -rf dotnet-install.sh;
# Install .NET Core 3.1 SDK binaries on Ubuntu 20.04
# Configuration adapted from: https://github.com/gitpod-io/workspace-images/blob/197b9ad25ed4b4af2b07facb62518f52d7715a07/dotnet/Dockerfile
# In order to get the download link:
# 1. Go to: https://dotnet.microsoft.com/download/dotnet-core
# 2. Select the version you want to download
# 3. Choose "Binaries" x64
# 4. In the new tab close the popup window
# 5. Copy the "Direct link" shown on the page and replace the URL in this file
RUN mkdir -p /home/gitpod/dotnet && curl -fsSL https://download.visualstudio.microsoft.com/download/pr/0c795076-b679-457e-8267-f9dd20a8ca28/02446ea777b6f5a5478cd3244d8ed65b/dotnet-sdk-3.1.300-linux-x64.tar.gz | tar xz -C /home/gitpod/dotnet
ENV DOTNET_ROOT=/home/gitpod/dotnet
ENV PATH=$PATH:/home/gitpod/dotnet
7 changes: 3 additions & 4 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@
"name": ".NET Core Launch (console)",
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build",
"program": "${workspaceRoot}/src/dotnet/Fable.Compiler/bin/Debug/netcoreapp2.1/dotnet-fable.dll",
"program": "${workspaceRoot}/src/Fable.Cli/bin/Debug/netcoreapp2.1/Fable.Cli.dll",
"args": ["fable-splitter", "--args", "-c tests/splitter.config.js"],
"cwd": "${workspaceRoot}",
"stopAtEntry": false,
Expand Down Expand Up @@ -51,7 +50,7 @@
"name": "bench-compile (Node)",
"program": "${workspaceRoot}/src/fable-standalone/test/bench-compiler/out-node/app.js",
// "args": ["${workspaceRoot}/tests/Main/Fable.Tests.fsproj", "out-tests", "--commonjs"],
"args": ["${workspaceRoot}/../fable-test/fable-test.fsproj", "out-test", "--commonjs", "--optimize-fcs"],
"args": ["${workspaceRoot}/../fable-test/fable-test.fsproj", "out-test", "--typescript"],
"cwd": "${workspaceRoot}/src/fable-standalone/test/bench-compiler"
},
{
Expand All @@ -60,7 +59,7 @@
"name": "bench-compile (.NET)",
"program": "${workspaceFolder}/src/fable-standalone/test/bench-compiler/bin/Debug/netcoreapp2.1/bench-compiler.dll",
// "args": ["${workspaceRoot}/tests/Main/Fable.Tests.fsproj", "out-tests", "--commonjs"],
"args": ["${workspaceRoot}/../fable-test/fable-test.fsproj", "out-test", "--commonjs", "--optimize-fcs"],
"args": ["${workspaceRoot}/../fable-test/fable-test.fsproj", "out-test", "--typescript"],
"cwd": "${workspaceFolder}/src/fable-standalone/test/bench-compiler"
},
{
Expand Down
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"sdk": {
"version": "3.1.201"
"version": "3.1.300"
}
}
2,015 changes: 933 additions & 1,082 deletions package-lock.json

Large diffs are not rendered by default.

20 changes: 10 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,27 +12,27 @@
},
"dependencies": {
"@babel/cli": "^7.8.4",
"@babel/core": "^7.9.0",
"@babel/plugin-transform-modules-commonjs": "^7.9.0",
"@babel/preset-env": "^7.9.0",
"@babel/core": "^7.9.6",
"@babel/plugin-transform-modules-commonjs": "^7.9.6",
"@babel/preset-env": "^7.9.6",
"@babel/register": "^7.9.0",
"@types/node": "^13.11.1",
"@types/node": "^14.0.5",
"babel-loader": "^8.1.0",
"concurrently": "^5.1.0",
"download-cli": "^1.1.1",
"fable-babel-plugins": "^2.3.0",
"fable-compiler": "^2.5.1",
"fable-compiler": "^2.9.0",
"fable-compiler-js": "^1.3.1",
"fable-loader": "^2.1.9",
"fable-splitter": "^2.1.13",
"ghreleases": "^3.0.2",
"mocha": "^7.1.1",
"nodemon": "^2.0.2",
"rollup": "^2.6.1",
"terser": "^4.6.11",
"tslint": "^6.1.1",
"typescript": "^3.8.3",
"webpack": "^4.42.1",
"rollup": "^2.10.8",
"terser": "^4.7.0",
"tslint": "^6.1.2",
"typescript": "^3.9.3",
"webpack": "^4.43.0",
"webpack-cli": "^3.3.11"
},
"devDependencies": {
Expand Down
6 changes: 3 additions & 3 deletions src/Fable.Cli/Fable.Cli.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
<Reference Include="../../lib/fcs/FSharp.Compiler.Service.dll" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Dotnet.ProjInfo" Version="0.36.0" />
<PackageReference Include="FSharp.Core" Version="4.7.1" />
<PackageReference Include="Newtonsoft.Json" Version="12.0.1" />
<PackageReference Include="Dotnet.ProjInfo" Version="0.39.1" />
<PackageReference Include="FSharp.Core" Version="4.7.2" />
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
</ItemGroup>
</Project>
6 changes: 6 additions & 0 deletions src/Fable.Cli/Parser.fs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ type Message =
define: string[]
typedArrays: bool
clampByteArrays: bool
classTypes: bool
typescript: bool
extra: IDictionary<string,string> }

let private parseStringArray (def: string[]) (key: string) (o: JObject) =
Expand Down Expand Up @@ -53,6 +55,8 @@ let private parseDic (key: string) (o: JObject): IDictionary<string,string> =
let toCompilerOptions (msg: Message): CompilerOptions =
{ typedArrays = msg.typedArrays
clampByteArrays = msg.clampByteArrays
classTypes = msg.classTypes
typescript = msg.typescript
debugMode = Array.contains "DEBUG" msg.define
verbosity = GlobalParams.Singleton.Verbosity
outputPublicInlinedFunctions = Array.contains "FABLE_REPL_LIB" msg.define
Expand All @@ -74,4 +78,6 @@ let parse (msg: string) =
|> Array.distinct
typedArrays = parseBoolean true "typedArrays" json
clampByteArrays = parseBoolean false "clampByteArrays" json
classTypes = parseBoolean false "classTypes" json
typescript = parseBoolean false "typescript" json
extra = parseDic "extra" json }
10 changes: 4 additions & 6 deletions src/Fable.Cli/ProjectCracker.fs
Original file line number Diff line number Diff line change
Expand Up @@ -268,12 +268,10 @@ let fullCrack (projFile: string): CrackedFsproj =
projRefs |> List.choose (fun projRef ->
// Remove dllRefs corresponding to project references
let projName = Path.GetFileNameWithoutExtension(projRef)
if projName = "Fable.Core" then None
else
let removed = dllRefs.Remove(projName)
if not removed then
Log.always("Couldn't remove project reference " + projName + " from dll references")
Path.normalizeFullPath projRef |> Some)
let removed = dllRefs.Remove(projName)
if not removed then
Log.always("Couldn't remove project reference " + projName + " from dll references")
Path.normalizeFullPath projRef |> Some)
let fablePkgs =
let dllRefs' = dllRefs |> Seq.map (fun (KeyValue(k,v)) -> k,v) |> Seq.toArray
dllRefs' |> Seq.choose (fun (dllName, dllPath) ->
Expand Down
2 changes: 1 addition & 1 deletion src/Fable.Cli/Util.fs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ namespace Fable.Cli

module Literals =

let [<Literal>] VERSION = "2.8.1"
let [<Literal>] VERSION = "2.10.0"
let [<Literal>] CORE_VERSION = "2.1.0"
let [<Literal>] DEFAULT_PORT = 61225
let [<Literal>] FORCE = "force:"
Expand Down
2 changes: 1 addition & 1 deletion src/Fable.Core/Fable.Core.JsInterop.fs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ let importSideEffects (path: string): unit = jsNative
let importDynamic<'T> (path: string): JS.Promise<'T> = jsNative

/// Imports a reference from an external file dynamically at runtime
/// ATENTION: Needs fable-compiler 2.3, pass the reference directly in argument position (avoid pipes)
/// ATTENTION: Needs fable-compiler 2.3, pass the reference directly in argument position (avoid pipes)
let importValueDynamic (x: 'T): JS.Promise<'T> = jsNative

/// Used when you need to send an F# record to a JS library accepting only plain JS objects (POJOs)
Expand Down
Loading

0 comments on commit a48d4bf

Please sign in to comment.