Skip to content

Commit

Permalink
Merge pull request #421 from TimeWarpEngineering/Cramer/2024-06-17/Yaml
Browse files Browse the repository at this point in the history
Include TimeWarp.State.SourceGenerator in the TimeWarp.State nuget.
  • Loading branch information
StevenTCramer authored Jun 18, 2024
2 parents dfe483c + 4efc5ca commit e821c52
Show file tree
Hide file tree
Showing 9 changed files with 49 additions and 17 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,12 @@ jobs:
cd ${{ github.workspace }}/Source/TimeWarp.State.Analyzer/
dotnet clean --configuration Debug
dotnet build --configuration Debug
- name: Build TimeWarp.State.SourceGenerator
run: |
cd ${{ github.workspace }}/Source/TimeWarp.State.SourceGenerator/
dotnet clean --configuration Debug
dotnet build --configuration Debug
- name: Build and Pack TimeWarp.State
run: |
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/publish-documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,15 @@ jobs:
cd ${{ github.workspace }}/Source/TimeWarp.State.Analyzer/
dotnet clean --configuration Release
dotnet build --configuration Release
cd ${{ github.workspace }}/Source/TimeWarp.State.SourceGenerator/
dotnet clean --configuration Release
dotnet build --configuration Release
cd ${{ github.workspace }}/Source/TimeWarp.State/
dotnet clean --configuration Release
dotnet build --configuration Release
cd ${{ github.workspace }}/Source/TimeWarp.State.Plus/
dotnet clean --configuration Release
dotnet build --configuration Release
- name: DocFX Build
working-directory: Documentation
Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,13 @@ jobs:
cd ${{ github.workspace }}/Source/TimeWarp.State.Analyzer/
dotnet clean --configuration Release
dotnet build --configuration Release
- name: Build TimeWarp.State.SourceGenerator
run: |
cd ${{ github.workspace }}/Source/TimeWarp.State.SourceGenerator/
dotnet clean --configuration Release
dotnet build --configuration Release
- name: Build and Pack TimeWarp.State
run: |
cd ${{ github.workspace }}/Source/TimeWarp.State/
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -308,5 +308,5 @@ __pycache__/
# Ignore all files in Razor Source Generators directories
**/Microsoft.NET.Sdk.Razor.SourceGenerators/**
**/Microsoft.CodeAnalysis.Razor.Compiler.SourceGenerators/**
/Source/TimeWarpState/wwwroot/js/**
/Source/TimeWarp.State/wwwroot/js/**
/Tests/Test.App.EndToEnd.Tests/Output/**
2 changes: 1 addition & 1 deletion Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<PropertyGroup>
<Authors>Steven T. Cramer</Authors>
<Product>TimeWarp State</Product>
<PackageVersion>11.0.0-beta.37+8.0.300</PackageVersion>
<PackageVersion>11.0.0-beta.38+8.0.300</PackageVersion>
<PackageProjectUrl>https://timewarpengineering.github.io/blazor-state/</PackageProjectUrl>
<PackageTags>TimeWarp.State; TimeWarp-State; TimeWarpState; BlazorState; Blazor; State; Blazor-State; MediatR; Mediator; Pipeline; Redux; Flux</PackageTags>
<PackageIcon>Logo.png</PackageIcon>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<EnforceExtendedAnalyzerRules>true</EnforceExtendedAnalyzerRules>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,21 @@
namespace TimeWarp.Features.Persistence;

public class PersistenceService
(
ISessionStorageService SessionStorageService,
ILocalStorageService LocalStorageService,
ILogger<PersistenceService> Logger
) : IPersistenceService
public class PersistenceService : IPersistenceService
{
private readonly JsonSerializerOptions JsonSerializerOptions = new();
private readonly ISessionStorageService SessionStorageService;
private readonly ILocalStorageService LocalStorageService;
private readonly ILogger<PersistenceService> Logger;
public PersistenceService
(
ISessionStorageService sessionStorageService,
ILocalStorageService localStorageService,
ILogger<PersistenceService> logger)
{
SessionStorageService = sessionStorageService;
LocalStorageService = localStorageService;
Logger = logger;
}
public async Task<object?> LoadState(Type stateType, PersistentStateMethod persistentStateMethod)
{
string typeName =
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,18 @@
namespace TimeWarp.State.Plus.PersistentState;

public class StateInitializedNotificationHandler
(
ISender Sender,
ILogger<StateInitializedNotificationHandler> logger
) : INotificationHandler<StateInitializedNotification>
public class StateInitializedNotificationHandler : INotificationHandler<StateInitializedNotification>
{
private ILogger Logger => logger;
private readonly ISender Sender;
private readonly ILogger<StateInitializedNotificationHandler> Logger;
public StateInitializedNotificationHandler
(
ISender sender,
ILogger<StateInitializedNotificationHandler> logger
)
{
Sender = sender;
Logger = logger;
}

public async Task Handle(StateInitializedNotification stateInitializedNotification, CancellationToken cancellationToken)
{
Expand Down
3 changes: 2 additions & 1 deletion Source/TimeWarp.State/TimeWarp.State.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@
</ItemGroup>

<ItemGroup>
<None Include="..\TimeWarp.State.Analyzer\bin\$(Configuration)\netstandard2.0\TimeWarp.State.Analyzer.dll" Pack="true" PackagePath="analyzers\dotnet\cs"/>
<None Include="..\TimeWarp.State.Analyzer\bin\$(Configuration)\net8.0\TimeWarp.State.Analyzer.dll" Pack="true" PackagePath="analyzers\dotnet\cs"/>
<None Include="..\TimeWarp.State.SourceGenerator\bin\$(Configuration)\net8.0\TimeWarp.State.SourceGenerator.dll" Pack="true" PackagePath="analyzers\dotnet\cs"/>
</ItemGroup>

<ItemGroup>
Expand Down

0 comments on commit e821c52

Please sign in to comment.