diff --git a/.config/dotnet-tools.json b/.config/dotnet-tools.json
index 68b85fe..3481788 100644
--- a/.config/dotnet-tools.json
+++ b/.config/dotnet-tools.json
@@ -6,19 +6,22 @@
"version": "5.22.0",
"commands": [
"fake"
- ]
+ ],
+ "rollForward": false
},
"paket": {
- "version": "7.1.5",
+ "version": "8.0.3",
"commands": [
"paket"
- ]
+ ],
+ "rollForward": false
},
"fsharp.formatting.commandtool": {
"version": "11.4.3",
"commands": [
"fsdocs"
- ]
+ ],
+ "rollForward": false
}
}
}
\ No newline at end of file
diff --git a/.editorconfig b/.editorconfig
new file mode 100644
index 0000000..f85d678
--- /dev/null
+++ b/.editorconfig
@@ -0,0 +1,27 @@
+# top-most EditorConfig file
+root = true
+
+[*]
+end_of_line = lf
+
+[*.{fs,fsi,fsx}]
+charset = utf-8
+indent_style = space
+indent_size = 4
+trim_trailing_whitespace = true
+max_line_length = 120
+insert_final_newline = true
+
+[*.{proto,props,targets,fsproj,csproj}]
+indent_size = 2
+indent_style = space
+trim_trailing_whitespace = true
+insert_final_newline = true
+
+[*.{yml,json,md,sh,ps1}]
+trim_trailing_whitespace = true
+insert_final_newline = true
+
+[{Dockerfile,.editorconfig,.gitignore}]
+trim_trailing_whitespace = true
+insert_final_newline = true
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 77c1967..17809d4 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -6,21 +6,22 @@ jobs:
build-windows:
name: CI (Windows)
runs-on: windows-latest
+ timeout-minutes: 25
steps:
- - uses: actions/checkout@v2
- - uses: actions/setup-dotnet@v1
+ - uses: actions/checkout@v3
+ - uses: actions/setup-dotnet@v3
with:
- dotnet-version: '6.0.400'
+ dotnet-version: 8.0.x
- name: Restore
run: |
dotnet tool restore
dotnet paket restore
- name: Build
- run: dotnet fake build
+ run: .\build.cmd -t Build
- name: Pack
run: |
- dotnet fake build -t PackAll
+ .\build.cmd -t PackAll
- name: Upload artifacts
uses: actions/upload-artifact@v2
with:
@@ -28,29 +29,28 @@ jobs:
path: artifacts
- name: Test
run: |
- dotnet fake build -t Test -- Release
+ .\build.cmd -t Test -- Release
build-macos:
name: CI (macOS)
runs-on: macos-latest
+ timeout-minutes: 25
steps:
- - uses: actions/checkout@v2
- - uses: actions/setup-dotnet@v1
+ - uses: actions/checkout@v3
+ - uses: actions/setup-dotnet@v3
with:
- dotnet-version: '6.0.400'
- - name: Install workloads
- run: |
- dotnet tool restore
- sudo dotnet workload install macos
+ dotnet-version: 8.0.x
- name: Restore
run: |
+ sudo dotnet workload install macos
dotnet tool restore
dotnet paket restore
+ dotnet restore Interstellar.MacOS.sln
- name: Build
- run: dotnet fake build -- Release
+ run: ./build.sh -t Build
- name: Pack
- run: dotnet fake build -t PackAll -- Release
+ run: ./build.sh -t PackAll
- name: Upload artifacts
uses: actions/upload-artifact@v2
with:
@@ -58,4 +58,33 @@ jobs:
path: artifacts/
- name: Test
run: |
- dotnet fake build -t Test -- Release
+ ./build.sh -t Test
+
+ build-ubuntu:
+ name: CI (Ubuntu)
+ runs-on: ubuntu-latest
+ timeout-minutes: 25
+
+ steps:
+ - uses: actions/checkout@v3
+ - uses: actions/setup-dotnet@v3
+ with:
+ dotnet-version: 8.0.x
+ - name: Restore
+ run: |
+ sudo dotnet workload install macos
+ dotnet tool restore
+ dotnet paket restore
+ dotnet restore Interstellar.MacOS.sln
+ - name: Build
+ run: ./build.sh -t Build
+ - name: Pack
+ run: ./build.sh -t PackAll
+ - name: Upload artifacts
+ uses: actions/upload-artifact@v2
+ with:
+ name: interstellar-linux
+ path: artifacts/
+ - name: Test
+ run: |
+ ./build.sh -t Test
diff --git a/.gitignore b/.gitignore
index e67a654..311f7a6 100644
--- a/.gitignore
+++ b/.gitignore
@@ -415,4 +415,4 @@ output/
temp/
# CEF
-GPUCache/
\ No newline at end of file
+GPUCache/
diff --git a/AssemblyAndPackageInfo.props b/AssemblyAndPackageInfo.props
index e30f659..90dd9de 100644
--- a/AssemblyAndPackageInfo.props
+++ b/AssemblyAndPackageInfo.props
@@ -16,4 +16,4 @@
-
\ No newline at end of file
+
diff --git a/Examples/Examples.GtkSharp.WebKit/Examples.GtkSharp.WebKit.fsproj b/Examples/Examples.GtkSharp.WebKit/Examples.GtkSharp.WebKit.fsproj
new file mode 100644
index 0000000..8fb4d6d
--- /dev/null
+++ b/Examples/Examples.GtkSharp.WebKit/Examples.GtkSharp.WebKit.fsproj
@@ -0,0 +1,18 @@
+
+
+
+ Exe
+ net8.0
+ Examples.Linux.Webkit
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Examples/Examples.GtkSharp.WebKit/Program.fs b/Examples/Examples.GtkSharp.WebKit/Program.fs
new file mode 100644
index 0000000..6c0f836
--- /dev/null
+++ b/Examples/Examples.GtkSharp.WebKit/Program.fs
@@ -0,0 +1,35 @@
+open System.Threading
+open Examples.SharedCode
+open Gtk
+open Interstellar
+open Interstellar.GtkSharp.Webkit
+open WebKit
+
+module Main =
+ let runApp () =
+ let mainCtx = SynchronizationContext.Current
+ Async.Start <| async {
+ let onMainWindowCreated (w: IBrowserWindow) =
+ let nativeWindow = w.NativeWindow
+ // This is where you could call some GTK-specific APIs on this window
+ ()
+ do! BrowserApp.runAsync mainCtx (SimpleBrowserApp.app onMainWindowCreated)
+ Application.Quit ()
+ }
+
+ []
+ let main argv =
+ Application.Init ()
+
+ // let wv = new WebView(WidthRequest = 400, HeightRequest = 100, Hexpand = true)
+ // let window = new Window("WebView Sample")
+ // window.Add wv
+ // wv.LoadUri "https://en.wikipedia.org/"
+ // window.DeleteEvent.Add (fun _ -> Application.Quit ())
+
+ // window.ShowAll ()
+
+ runApp ()
+
+ Application.Run ()
+ 0
diff --git a/Examples/Examples.GtkSharp.WebKit/paket.references b/Examples/Examples.GtkSharp.WebKit/paket.references
new file mode 100644
index 0000000..6f627f4
--- /dev/null
+++ b/Examples/Examples.GtkSharp.WebKit/paket.references
@@ -0,0 +1 @@
+FSharp.Core
diff --git a/Examples/Examples.SharedCode/Library.fs b/Examples/Examples.SharedCode/Library.fs
index b7b88a1..6e324f2 100644
--- a/Examples/Examples.SharedCode/Library.fs
+++ b/Examples/Examples.SharedCode/Library.fs
@@ -221,6 +221,8 @@ module SimpleBrowserApp =
- %s
+
+