Skip to content

Commit

Permalink
fix(github actions): resolve bit 8.7.0 minor issues #6526 (#6527)
Browse files Browse the repository at this point in the history
  • Loading branch information
ysmoradi authored Jan 9, 2024
1 parent 8539826 commit 12db02e
Show file tree
Hide file tree
Showing 25 changed files with 54 additions and 35 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/admin-sample.cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,9 @@ jobs:

- name: Install maui
run: cd src && dotnet workload install maui-android

- name: Install Android Dependencies
run: dotnet build AdminPanel/src/Client/AdminPanel.Client.Maui/AdminPanel.Client.Maui.csproj -t:InstallAndroidDependencies -f:net8.0-android -p:AcceptAndroidSDKLicenses=True -p:AndroidSdkPath="/usr/local/lib/android/sdk/"

- name: Generate CSS/JS files
run: dotnet build AdminPanel/src/Client/AdminPanel.Client.Core/AdminPanel.Client.Core.csproj -t:BeforeBuildTasks --no-restore
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/bit.ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ jobs:
- name: Install wasm and maui
run: cd src && dotnet workload install maui-android wasm-tools wasm-experimental

- name: Install Android Dependencies
run: dotnet build src/BlazorUI/Demo/Client/Bit.BlazorUI.Demo.Client.Maui/Bit.BlazorUI.Demo.Client.Maui.csproj -t:InstallAndroidDependencies -f:net8.0-android -p:AcceptAndroidSDKLicenses=True -p:AndroidSdkPath="/usr/local/lib/android/sdk/"

- name: Build
run: dotnet build src/Bit-CI.sln -p:WarningLevel=0 -p:RunCodeAnalysis=false

Expand Down
1 change: 1 addition & 0 deletions .github/workflows/bit.full.ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ jobs:
run: |
dotnet workload install maui-tizen maui-android wasm-tools wasm-experimental
dotnet new bit-bp --name TodoBPSqlite --database sqlite --sample todo --pipeline other
dotnet build TodoBPSqlite/src/Client/TodoBPSqlite.Client.Maui/TodoBPSqlite.Client.Maui.csproj -t:InstallAndroidDependencies -f:net8.0-android -p:AcceptAndroidSDKLicenses=True -p:AndroidSdkPath="/usr/local/lib/android/sdk/"
cd TodoBPSqlite/src/TodoBPSqlite.Server/
dotnet tool restore
dotnet ef migrations add InitialMigration
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/blazorui.demo.cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,9 @@ jobs:

- name: Install maui
run: cd src && dotnet workload install maui-android

- name: Install Android Dependencies
run: dotnet build src/BlazorUI/Demo/Client/Bit.BlazorUI.Demo.Client.Maui/Bit.BlazorUI.Demo.Client.Maui.csproj -t:InstallAndroidDependencies -f:net8.0-android -p:AcceptAndroidSDKLicenses=True -p:AndroidSdkPath="/usr/local/lib/android/sdk/"

- name: Generate CSS/JS files
run: dotnet build src/BlazorUI/Demo/Client/Bit.BlazorUI.Demo.Client.Core/Bit.BlazorUI.Demo.Client.Core.csproj -c Release
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/todo-sample.cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,9 @@ jobs:

- name: Install maui
run: cd src && dotnet workload install maui-android

- name: Install Android Dependencies
run: dotnet build TodoSample/src/Client/TodoSample.Client.Maui/TodoSample.Client.Maui.csproj -t:InstallAndroidDependencies -f:net8.0-android -p:AcceptAndroidSDKLicenses=True -p:AndroidSdkPath="/usr/local/lib/android/sdk/"

- name: Generate CSS/JS files
run: dotnet build TodoSample/src/Client/TodoSample.Client.Core/TodoSample.Client.Core.csproj -t:BeforeBuildTasks --no-restore
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
</ItemGroup>

<Target Name="BeforeBuildTasks" AfterTargets="CoreCompile" Condition="'$(TargetFramework)' == 'net8.0'">
<Exec Condition="!Exists('node_modules/.bin/sass')" Command="npm install [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Condition="!Exists('node_modules/.bin/sass')" Command="npm install [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Command="node_modules/.bin/sass Styles/bit.blazorui.assets.scss:wwwroot/styles/bit.blazorui.assets.css --style compressed --load-path=. --update" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
</Target>

Expand Down
4 changes: 2 additions & 2 deletions src/BlazorUI/Bit.BlazorUI.Extras/Bit.BlazorUI.Extras.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,9 @@
</ItemGroup>

<Target Name="BeforeBuildTasks" AfterTargets="CoreCompile" Condition="'$(TargetFramework)' == 'net8.0'">
<Exec Condition="!Exists('node_modules/.bin/sass') OR !Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Condition="!Exists('node_modules/.bin/sass') OR !Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Command="node_modules/.bin/sass Styles/bit.blazorui.extras.scss:wwwroot/styles/bit.blazorui.extras.css --style compressed --load-path=. --update" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Condition=" '$(Configuration)' == 'Release' " Command="node_modules/.bin/esbuild wwwroot/scripts/bit.blazorui.extras.js --minify --outfile=wwwroot/scripts/bit.blazorui.extras.js --allow-overwrite" StandardOutputImportance="high" StandardErrorImportance="high" />
</Target>

Expand Down
2 changes: 1 addition & 1 deletion src/BlazorUI/Bit.BlazorUI.Icons/Bit.BlazorUI.Icons.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
</ItemGroup>

<Target Name="BeforeBuildTasks" AfterTargets="CoreCompile" Condition="'$(TargetFramework)' == 'net8.0'">
<Exec Condition="!Exists('node_modules/.bin/sass')" Command="npm install [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Condition="!Exists('node_modules/.bin/sass')" Command="npm install [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Command="node_modules/.bin/sass Styles/bit.blazorui.icons.scss:wwwroot/styles/bit.blazorui.icons.css --style compressed --load-path=. --update" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
</Target>

Expand Down
4 changes: 2 additions & 2 deletions src/BlazorUI/Bit.BlazorUI/Bit.BlazorUI.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@
</ItemGroup>

<Target Name="BeforeBuildTasks" AfterTargets="CoreCompile" Condition="'$(TargetFramework)' == 'net8.0'">
<Exec Condition="!Exists('node_modules/.bin/sass') OR !Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Condition="!Exists('node_modules/.bin/sass') OR !Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Command="node_modules/.bin/sass Styles/bit.blazorui.scss:wwwroot/styles/bit.blazorui.css Styles/Fluent/bit.blazorui.fluent.scss:wwwroot/styles/bit.blazorui.fluent.css Styles/Fluent/bit.blazorui.fluent-dark.scss:wwwroot/styles/bit.blazorui.fluent-dark.css Styles/Fluent/bit.blazorui.fluent-light.scss:wwwroot/styles/bit.blazorui.fluent-light.css --style compressed --load-path=. --update" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Condition=" '$(Configuration)' == 'Release' " Command="node_modules/.bin/esbuild wwwroot/scripts/bit.blazorui.js --minify --outfile=wwwroot/scripts/bit.blazorui.js --allow-overwrite" StandardOutputImportance="high" StandardErrorImportance="high" />
</Target>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,9 @@
</ItemGroup>

<Target Name="BeforeBuildTasks" AfterTargets="CoreCompile">
<Exec Condition="!Exists('node_modules/.bin/sass') OR !Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Condition="!Exists('node_modules/.bin/sass') OR !Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Command="node_modules/.bin/sass .:. Styles/app.scss:wwwroot/styles/app.css --style compressed --load-path=. --update" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Condition=" '$(Configuration)' == 'Release' " Command="node_modules/.bin/esbuild wwwroot/scripts/app.js --minify --outfile=wwwroot/scripts/app.js --allow-overwrite" StandardOutputImportance="high" StandardErrorImportance="high" />
</Target>

Expand Down
4 changes: 2 additions & 2 deletions src/Bswup/Bit.Bswup/Bit.Bswup.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@
</ItemGroup>

<Target Name="BeforeBuildTasks" AfterTargets="CoreCompile" Condition="'$(TargetFramework)' == 'net8.0'">
<Exec Condition="!Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Condition="!Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Condition=" '$(Configuration)' == 'Release' " Command="node_modules/.bin/esbuild wwwroot/bit-bswup.js --minify --outfile=wwwroot/bit-bswup.js --allow-overwrite" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Condition=" '$(Configuration)' == 'Release' " Command="node_modules/.bin/esbuild wwwroot/bit-bswup.progress.js --minify --outfile=wwwroot/bit-bswup.progress.js --allow-overwrite" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Condition=" '$(Configuration)' == 'Release' " Command="node_modules/.bin/esbuild wwwroot/bit-bswup.sw.js --minify --outfile=wwwroot/bit-bswup.sw.js --allow-overwrite" StandardOutputImportance="high" StandardErrorImportance="high" />
Expand Down
4 changes: 2 additions & 2 deletions src/Bup/Bit.Bup/Bit.Bup.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@
</ItemGroup>

<Target Name="BeforeBuildTasks" AfterTargets="CoreCompile" Condition="'$(TargetFramework)' == 'net8.0'">
<Exec Condition="!Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Condition="!Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Condition=" '$(Configuration)' == 'Release' " Command="node_modules/.bin/esbuild wwwroot/bit-bup.js --minify --outfile=wwwroot/bit-bup.js --allow-overwrite" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Condition=" '$(Configuration)' == 'Release' " Command="node_modules/.bin/esbuild wwwroot/bit-bup.progress.js --minify --outfile=wwwroot/bit-bup.progress.js --allow-overwrite" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Command="node_modules/.bin/esbuild Styles/bit-bup.progress.css --minify --outfile=wwwroot/bit-bup.progress.css" StandardOutputImportance="high" StandardErrorImportance="high" />
Expand Down
4 changes: 2 additions & 2 deletions src/Butil/Bit.Butil/Bit.Butil.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
</ItemGroup>

<Target Name="BeforeBuildTasks" AfterTargets="CoreCompile" Condition="'$(TargetFramework)' == 'net8.0'">
<Exec Condition="!Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Condition="!Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Condition=" '$(Configuration)' == 'Release' " Command="node_modules/.bin/esbuild wwwroot/bit-butil.js --minify --outfile=wwwroot/bit-butil.js --allow-overwrite" StandardOutputImportance="high" StandardErrorImportance="high" />
</Target>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,12 @@ jobs:
targetType: 'inline'
script: cd src && dotnet workload install maui-android

- task: Bash@3
displayName: 'Install Android Dependencies'
inputs:
targetType: 'inline'
script: 'dotnet build src/Client/Boilerplate.Client.Maui/Boilerplate.Client.Maui.csproj -t:InstallAndroidDependencies -f:net8.0-android -p:AcceptAndroidSDKLicenses=True -p:AndroidSdkPath="/usr/local/lib/android/sdk/"'

- task: DownloadSecureFile@1
displayName: Download Boilerplate keystore file
name: AndroidKeyStore
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -195,9 +195,12 @@ jobs:
files: 'src/Client/Boilerplate.Client.Core/appsettings.json'
env:
ApiServerAddress: ${{ env.API_SERVER_ADDRESS }}

- name: Install maui
run: cd src && dotnet workload install maui-android

- name: Install Android Dependencies
run: dotnet build src/Client/Boilerplate.Client.Maui/Boilerplate.Client.Maui.csproj -t:InstallAndroidDependencies -f:net8.0-android -p:AcceptAndroidSDKLicenses=True -p:AndroidSdkPath="/usr/local/lib/android/sdk/"

- name: Generate CSS/JS files
run: dotnet build src/Client/Boilerplate.Client.Core/Boilerplate.Client.Core.csproj -t:BeforeBuildTasks --no-restore
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,9 @@
</ItemGroup>

<Target Name="BeforeBuildTasks" AfterTargets="CoreCompile">
<Exec Condition="!Exists('node_modules/.bin/sass') OR !Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Condition="!Exists('node_modules/.bin/sass') OR !Exists('node_modules/.bin/esbuild') OR !Exists('node_modules/.bin/tsc')" Command="npm install [email protected] [email protected] [email protected] --no-save" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Command="node_modules/.bin/sass .:. Styles/app.scss:wwwroot/styles/app.css --style compressed --load-path=. --update" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" LogStandardErrorAsError="true" />
<Exec Command="node_modules/.bin/tsc" StandardOutputImportance="high" StandardErrorImportance="high" />
<Exec Condition=" '$(Configuration)' == 'Release' " Command="node_modules/.bin/esbuild wwwroot/scripts/app.js --minify --outfile=wwwroot/scripts/app.js --allow-overwrite" StandardOutputImportance="high" StandardErrorImportance="high" />
</Target>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ async void VerifyUserIsAuthenticatedOrNot(Task<AuthenticationState> task)
}
finally
{
StateHasChanged();
await InvokeAsync(StateHasChanged);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ async void VerifyUserIsAuthenticatedOrNot(Task<AuthenticationState> task)
}
finally
{
StateHasChanged();
await InvokeAsync(StateHasChanged);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ protected override async Task OnInitAsync()

SetProfileImageUrl();

StateHasChanged();
await InvokeAsync(StateHasChanged);
});

user = await userController.GetCurrentUser(CurrentCancellationToken);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,16 @@ public partial class OfflineEditProfilePage
private UserDto user = new();
private readonly EditUserDto userToEdit = new();

protected async override Task OnAfterFirstRenderAsync()
protected override async Task OnInitAsync()
{
await base.OnAfterFirstRenderAsync();

await base.OnInitAsync();
try
{
await LoadEditProfileData();
}
finally
{
isLoading = false;
StateHasChanged();
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ The usage of `Bit.Besql` is exactly the same as the regular usage of `Microsoft.

To get start, simply install `Bit.Besql` and use `services.AddBesqlDbContextFactory` instead of `services.AddDbContextFactory`.

Note: Don't use `IDbContextFactory` in `OnInitialized` because it relies on `IJSRuntime`. Use `OnAfterRender` instead.

In order to download sqlite db file from browser cache storage in blazor WebAssembly run the followings in browser console:
```js
const cache = await caches.open('Bit-Besql');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@ self.assetsExclude = [
/bit\.blazorui\.fluent\.css$/,
/bit\.blazorui\.fluent-dark\.css$/,
/bit\.blazorui\.fluent-light\.css$/,
/Boilerplate\.Client\.Web\.styles\.css$/
/Client\.Web\.styles\.css$/ // In .NET 8, an inexistent CSS file is inadvertently included in the assets list under the name 'Boilerplate.Client.Web.styles.css.'
// Subsequently, during the download process of assets list files, bswup attempts to retrieve this non - existent CSS file along with others.
// It is imperative that we expunge this file from the assets list.
];
self.externalAssets = [
{
Expand All @@ -28,10 +30,9 @@ self.serverHandledUrls = [
/\/swagger/
];

self.isPassive = true;
self.defaultUrl = "/";
self.caseInsensitiveUrl = true;
self.noPrerenderQuery = 'no-prerender=true';
self.disablePassiveFirstBoot = true;
self.isPassive = self.disablePassiveFirstBoot = true;

self.importScripts('_content/Bit.Bswup/bit-bswup.sw.js');
Loading

0 comments on commit 12db02e

Please sign in to comment.