Skip to content

Commit

Permalink
Merge branch 'master' into icons
Browse files Browse the repository at this point in the history
  • Loading branch information
zeusongit authored Feb 20, 2024
2 parents 80c936b + a30f1e3 commit a1c0dc2
Show file tree
Hide file tree
Showing 79 changed files with 9,592 additions and 572 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ jobs:
uses: microsoft/[email protected]
- name: Install dependencies for windows runtime
run: |
dotnet restore ${{ github.workspace }}\Dynamo\src\Dynamo.All.sln /p:Configuration=Release --runtime=win-x64 -p:DotNet=net8.0
dotnet restore ${{ github.workspace }}\Dynamo\src\Dynamo.All.sln /p:Configuration=Release --runtime=win-x64
- name: Build Dynamo with MSBuild for Windows
run: |
Write-Output "***Continue with the build, Good luck developer!***"
msbuild ${{ github.workspace }}\Dynamo\src\Dynamo.All.sln /p:Configuration=Release /p:DotNet=net8.0
msbuild ${{ github.workspace }}\Dynamo\src\Dynamo.All.sln /p:Configuration=Release
- name: Look for DynamoCLI.exe
run: |
Write-Output "***Locating DynamoCLI.exe!***"
Expand Down
41 changes: 0 additions & 41 deletions .github/workflows/build_dynamo_all_net6.0.yml

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Build DynamoCore.sln with .NET 6.0 on linux
name: Build DynamoCore.sln net6.0 linux
# Build DynamoCore.sln with .NET 8.0 on linux
name: Build DynamoCore.sln net8.0 linux

on:
push:
Expand All @@ -17,22 +17,24 @@ jobs:
path: Dynamo
- name: Setup dotnet
uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Disable problem matcher
run: echo "::remove-matcher owner=csc::"
- name: Install dependencies for linux runtime
run: dotnet restore ${{ github.workspace }}/Dynamo/src/DynamoCore.sln -p:Platform=NET60_Linux --runtime=linux-x64
run: dotnet restore ${{ github.workspace }}/Dynamo/src/DynamoCore.sln -p:Platform=NET_Linux --runtime=linux-x64
- name: Build Dynamo with MSBuild for Linux
run: |
echo "***Continue with the build, Good luck developer!***"
dotnet build ${{ github.workspace }}/Dynamo/src/DynamoCore.sln -c Release /p:Platform=NET60_Linux
dotnet build ${{ github.workspace }}/Dynamo/src/DynamoCore.sln -c Release /p:Platform=NET_Linux
- name: Look for DynamoCLI.exe
run: |
cd "${{ github.workspace }}/Dynamo/bin/NET60_Linux/Release"
cd "${{ github.workspace }}/Dynamo/bin/NET_Linux/Release"
echo "***Locating DynamoCLI for Linux!***"
test "./DynamoCLI.exe" && echo "DynamoCLI exists!"
- name: Run smoke tests
run: |
cd "${{ github.workspace }}/Dynamo/bin/NET60_Linux/Release"
cd "${{ github.workspace }}/Dynamo/bin/NET_Linux/Release"
echo "***Running Smoke tests on linux***"
#TODO unfortunately dotnet does not find any tests in this assembly.
#dotnet test DynamoCoreTests.dll --filter "TestCategory~UnitTest"
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
- name: Setup dotnet
uses: actions/setup-dotnet@v4
with:
dotnet-version: '6.0.x'
dotnet-version: '8.0.x'
- name: Disable problem matcher
run: Write-Output "::remove-matcher owner=csc::"
- name: Setup msbuild
Expand All @@ -40,15 +40,15 @@ jobs:
Write-Error "DynamoCLI.exe was not found!"
}
- name: Install dependencies for linux runtime
run: dotnet restore ${{ github.workspace }}\Dynamo\src\DynamoCore.sln -p:Platform=NET60_Linux --runtime=linux-x64
run: dotnet restore ${{ github.workspace }}\Dynamo\src\DynamoCore.sln -p:Platform=NET_Linux --runtime=linux-x64
- name: Build Dynamo with MSBuild for Linux
run: |
Write-Output "***Continue with the build, Good luck developer!***"
msbuild ${{ github.workspace }}\Dynamo\src\DynamoCore.sln /p:Configuration=Release /p:Platform=NET60_Linux
msbuild ${{ github.workspace }}\Dynamo\src\DynamoCore.sln /p:Configuration=Release /p:Platform=NET_Linux
- name: Look for DynamoCLI
run: |
Write-Output "***Locating DynamoCLI for Linux!***"
if (Test-Path -Path "${{ github.workspace }}\Dynamo\bin\NET60_Linux\Release\DynamoCLI") {
if (Test-Path -Path "${{ github.workspace }}\Dynamo\bin\NET_Linux\Release\DynamoCLI") {
Write-Output "DynamoCLI exists!"
} else {
Write-Error "DynamoCLI was not found!"
Expand Down
37 changes: 37 additions & 0 deletions .github/workflows/dynamo_api_break.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: API Break Analysis

on:
pull_request:
types:
- opened
- synchronize

jobs:
analyze:
runs-on: windows-latest

steps:
- name: Checkout Dynamo Repo
uses: actions/checkout@v4
with:
path: Dynamo
repository: DynamoDS/Dynamo

- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'

- name: Setup msbuild
uses: microsoft/[email protected]

- name: Install dependencies for windows runtime
run: |
dotnet restore ${{ github.workspace }}\Dynamo\src\Dynamo.All.sln /p:Configuration=Release --runtime=win-x64
- name: Build and analyze
run: |
Write-Output "***Continue with the build, Good luck developer!***"
msbuild ${{ github.workspace }}\Dynamo\src\Dynamo.All.sln /p:Configuration=Release /warnAsError:RS0016 /p:PublicApiAnalyzers=true
2 changes: 1 addition & 1 deletion .github/workflows/generate_changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
uses: actions/checkout@v4
- name: Generate changelog
id: generate_changelog
uses: metcalfc/[email protected].0
uses: metcalfc/[email protected].1
with:
myToken: ${{ secrets.GITHUB_TOKEN }}
head-ref: ${{ github.event.inputs.head-ref }}
Expand Down
7 changes: 3 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
# Dynamo

[![Build DynamoAll.sln net6.0](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_all_net6.0.yml/badge.svg)](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_all_net6.0.yml)
[![Build DynamoAll.sln net8.0](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_all_net8.0.yml/badge.svg)](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_all_net8.0.yml)
[![Build DynamoCore.sln net6.0 windows](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_core_net6.0_windows.yml/badge.svg)](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_core_net6.0_windows.yml)
[![Build DynamoCore.sln net6.0 linux](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_core_net6.0_linux.yml/badge.svg)](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_core_net6.0_linux.yml)
[![Build DynamoAll.sln net8.0](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_all.yml/badge.svg)](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_all.yml)
[![Build DynamoCore.sln core windows](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_core_windows.yml/badge.svg)](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_core_windows.yml)
[![Build DynamoCore.sln linux](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_core_linux.yml/badge.svg)](https://github.com/DynamoDS/Dynamo/actions/workflows/build_dynamo_core_linux.yml)

[![DynamoCoreRuntime](https://img.shields.io/github/v/release/DynamoDS/Dynamo?logo=github&label=DynamoCoreRuntime)](https://github.com/DynamoDS/Dynamo/releases/latest)
[![Nuget](https://img.shields.io/nuget/v/DynamoVisualProgramming.Core?logo=nuget)](https://www.nuget.org/packages/DynamoVisualProgramming.Core)
Expand Down
2 changes: 1 addition & 1 deletion src/Config/CS_SDK.props
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project>
<PropertyGroup>
<Platforms>AnyCPU;NET60_Linux;</Platforms>
<Platforms>AnyCPU;NET_Linux;</Platforms>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<PlatformTarget >x64</PlatformTarget>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -170,22 +170,30 @@ async void InitializeAsync()
};
}

//Initialize the CoreWebView2 component otherwise we can't navigate to a web page
await documentationBrowser.EnsureCoreWebView2Async();

this.documentationBrowser.CoreWebView2.WebMessageReceived += CoreWebView2OnWebMessageReceived;
comScriptingObject = new ScriptingObject(this.viewModel);
//register the interop object into the browser.
this.documentationBrowser.CoreWebView2.AddHostObjectToScript("bridge", comScriptingObject);

this.documentationBrowser.CoreWebView2.Settings.IsZoomControlEnabled = true;
this.documentationBrowser.CoreWebView2.Settings.AreDevToolsEnabled = true;

initState = AsyncMethodState.Done;
try
{
//Initialize the CoreWebView2 component otherwise we can't navigate to a web page
await documentationBrowser.Initialize(Log);

this.documentationBrowser.CoreWebView2.WebMessageReceived += CoreWebView2OnWebMessageReceived;
comScriptingObject = new ScriptingObject(this.viewModel);
//register the interop object into the browser.
this.documentationBrowser.CoreWebView2.AddHostObjectToScript("bridge", comScriptingObject);

this.documentationBrowser.CoreWebView2.Settings.IsZoomControlEnabled = true;
this.documentationBrowser.CoreWebView2.Settings.AreDevToolsEnabled = true;

initState = AsyncMethodState.Done;
}
catch(ObjectDisposedException ex)
{
Log(ex.Message);
}

}
//if we make it this far, for example to do re-entry to to this method, while we're still
//initializing, don't do anything, just bail.
if(initState == AsyncMethodState.Done)
if (initState == AsyncMethodState.Done)
{
if (Directory.Exists(VirtualFolderPath))
{
Expand All @@ -211,11 +219,6 @@ private void CoreWebView2OnWebMessageReceived(object sender, CoreWebView2WebMess
/// </summary>
public void Dispose()
{
if (initState == AsyncMethodState.Started)
{
Log("DocumentationBrowserView is being disposed but async initialization is still not done");
}

Dispose(true);
GC.SuppressFinalize(this);
}
Expand Down
1 change: 0 additions & 1 deletion src/DynamoApplications/StartupUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,6 @@ public static void PreloadShapeManager(ref string geometryFactoryPath, ref strin
var versions = new[]
{
new Version(230,0,0),
new Version(229,0,0),
};

var preloader = new Preloader(rootFolder, versions);
Expand Down
Loading

0 comments on commit a1c0dc2

Please sign in to comment.