<commit_before>name: CI Workflow

on:
  push:
    branches: [ master ]

jobs:
  Build_Services:
    runs-on: windows-latest
    env:
      BuildConfiguration: Release
      BuildPlatform: Any CPU

    steps:
    - uses: actions/checkout@v2
    
    - name: Version Assemblies
      run: ./deploy/VersionAssemblies.ps1 -MajorVersion 0 -MinorVersion 1 -BuildNumber $env:GITHUB_RUN_NUMBER -SourcesDir . -Verbose
      shell: powershell
      
    - name: Install Nuget
      uses: nuget/setup-nuget@v1
      with:
        nuget-version: latest

    - name: NuGet Restore
      run: nuget restore ./src/PokerLeagueManager.sln
  
    - name: Setup MSBuild
      uses: microsoft/setup-msbuild@v1.0.0
    
    - name: Build Solution
      run: msbuild ./src/PokerLeagueManager.sln /p:TreatWarningsAsErrors=true /p:CodeAnalysisRuleSet="../PokerLeagueManager.ruleset" /p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:ValidateArchitecture=true /p:"platform=$env:BuildPlatform" /p:configuration="$env:BuildConfiguration"
      
    - name: Setup VSTest
      uses: Malcolmnixon/Setup-VSTest@v2
      
    - name: Run Unit Tests
      run: vstest.console "src\PokerLeagueManager.Commands.Tests\bin\$env:BuildConfiguration\PokerLeagueManager.Commands.Tests.dll" "src\PokerLeagueManager.Infrastructure.Tests\bin\$env:BuildConfiguration\PokerLeagueManager.Infrastructure.Tests.dll" "src\PokerLeagueManager.Queries.Tests\bin\$env:BuildConfiguration\PokerLeagueManager.Queries.Tests.dll" /Logger:"trx" /Parallel /Blame

    - name: Publish QueryStore Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: DB.QueryStore
        path: db/QueryStore

    - name: Publish EventStore Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: DB.EventStore
        path: db/EventStore

    - name: Publish Commands.WebApi Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: WebApi.Commands
        path: src/PokerLeagueManager.Commands.WebApi/obj/Release/Package/PokerLeagueManager.Commands.WebApi.zip

    - name: Publish Events.WebApi Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: WebApi.Events
        path: src/PokerLeagueManager.Events.WebApi/obj/Release/Package/PokerLeagueManager.Events.WebApi.zip

    - name: Publish Queries.WebApi Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: WebApi.Queries
        path: src/PokerLeagueManager.Queries.WebApi/obj/Release/Package/PokerLeagueManager.Queries.WebApi.zip

    - name: Publish Deploy Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: Deploy
        path: deploy

    - name: Publish Utilities Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: Utilities
        path: src/PokerLeagueManager.Utilities/bin/Release

  Build_Web:
    runs-on: windows-latest
    env:
      BuildConfiguration: Release
      BuildPlatform: Any CPU

    steps:
    - uses: actions/checkout@v2
    
    - name: Version Assemblies
      run: ./deploy/VersionAssemblies.ps1 -MajorVersion 0 -MinorVersion 1 -BuildNumber $env:GITHUB_RUN_NUMBER -SourcesDir . -Verbose
      shell: powershell
      
    - name: Install Nuget
      uses: nuget/setup-nuget@v1
      with:
        nuget-version: latest

    - name: NuGet Restore
      run: nuget restore ./src/PokerLeagueManager.UI.Web/PokerLeagueManager.UI.Web.csproj
  
    - name: Setup MSBuild
      uses: microsoft/setup-msbuild@v1.0.0
    
    - name: Setup Node
      uses: actions/setup-node@v1.1.0
      with:
        node-version: 12.x
    
    - name: npm ci
      run: npm ci
      working-directory: ./src/PokerLeagueManager.UI.Web/angular
      
    - name: Generate TypeScript Lib
      run: GenerateTypeScript.bat
      working-directory: ./src/PokerLeagueManager.UI.Web
      shell: cmd
      
    - name: Build Angular
      run: npm run build-prod
      working-directory: ./src/PokerLeagueManager.UI.Web/angular
      
    - name: Create index.cshtml
      run: ./deploy/TransformIndex.ps1 -SourcePath ./src/PokerLeagueManager.UI.Web/angular/dist/index.html -TargetPath ./src/PokerLeagueManager.UI.Web/angular/dist/index.cshtml
      shell: powershell
    
    - name: Run Jasmine Tests
      run: npm run test-prod
      working-directory: ./src/PokerLeagueManager.UI.Web/angular
    
    - name: Build UI.Web
      run: msbuild ./src/PokerLeagueManager.UI.Web/PokerLeagueManager.UI.Web.csproj /p:TreatWarningsAsErrors=true /p:CodeAnalysisRuleSet="../PokerLeagueManager.ruleset" /p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:ValidateArchitecture=true /p:"platform=$env:BuildPlatform" /p:configuration="$env:BuildConfiguration"

    - name: Publish UI.Web Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: UI.Web
        path: src/PokerLeagueManager.UI.Web/obj/Release/Package/PokerLeagueManager.UI.Web.zip
<commit_msg>changed nuget restore to always use solution<commit_after>name: CI Workflow

on:
  push:
    branches: [ master ]

jobs:
  Build_Services:
    runs-on: windows-latest
    env:
      BuildConfiguration: Release
      BuildPlatform: Any CPU

    steps:
    - uses: actions/checkout@v2
    
    - name: Version Assemblies
      run: ./deploy/VersionAssemblies.ps1 -MajorVersion 0 -MinorVersion 1 -BuildNumber $env:GITHUB_RUN_NUMBER -SourcesDir . -Verbose
      shell: powershell
      
    - name: Install Nuget
      uses: nuget/setup-nuget@v1
      with:
        nuget-version: latest

    - name: NuGet Restore
      run: nuget restore ./src/PokerLeagueManager.sln
  
    - name: Setup MSBuild
      uses: microsoft/setup-msbuild@v1.0.0
    
    - name: Build Solution
      run: msbuild ./src/PokerLeagueManager.sln /p:TreatWarningsAsErrors=true /p:CodeAnalysisRuleSet="../PokerLeagueManager.ruleset" /p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:ValidateArchitecture=true /p:"platform=$env:BuildPlatform" /p:configuration="$env:BuildConfiguration"
      
    - name: Setup VSTest
      uses: Malcolmnixon/Setup-VSTest@v2
      
    - name: Run Unit Tests
      run: vstest.console "src\PokerLeagueManager.Commands.Tests\bin\$env:BuildConfiguration\PokerLeagueManager.Commands.Tests.dll" "src\PokerLeagueManager.Infrastructure.Tests\bin\$env:BuildConfiguration\PokerLeagueManager.Infrastructure.Tests.dll" "src\PokerLeagueManager.Queries.Tests\bin\$env:BuildConfiguration\PokerLeagueManager.Queries.Tests.dll" /Logger:"trx" /Parallel /Blame

    - name: Publish QueryStore Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: DB.QueryStore
        path: db/QueryStore

    - name: Publish EventStore Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: DB.EventStore
        path: db/EventStore

    - name: Publish Commands.WebApi Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: WebApi.Commands
        path: src/PokerLeagueManager.Commands.WebApi/obj/Release/Package/PokerLeagueManager.Commands.WebApi.zip

    - name: Publish Events.WebApi Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: WebApi.Events
        path: src/PokerLeagueManager.Events.WebApi/obj/Release/Package/PokerLeagueManager.Events.WebApi.zip

    - name: Publish Queries.WebApi Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: WebApi.Queries
        path: src/PokerLeagueManager.Queries.WebApi/obj/Release/Package/PokerLeagueManager.Queries.WebApi.zip

    - name: Publish Deploy Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: Deploy
        path: deploy

    - name: Publish Utilities Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: Utilities
        path: src/PokerLeagueManager.Utilities/bin/Release

  Build_Web:
    runs-on: windows-latest
    env:
      BuildConfiguration: Release
      BuildPlatform: Any CPU

    steps:
    - uses: actions/checkout@v2
    
    - name: Version Assemblies
      run: ./deploy/VersionAssemblies.ps1 -MajorVersion 0 -MinorVersion 1 -BuildNumber $env:GITHUB_RUN_NUMBER -SourcesDir . -Verbose
      shell: powershell
      
    - name: Install Nuget
      uses: nuget/setup-nuget@v1
      with:
        nuget-version: latest

    - name: NuGet Restore
      run: nuget restore ./src/PokerLeagueManager.sln
  
    - name: Setup MSBuild
      uses: microsoft/setup-msbuild@v1.0.0
    
    - name: Setup Node
      uses: actions/setup-node@v1.1.0
      with:
        node-version: 12.x
    
    - name: npm ci
      run: npm ci
      working-directory: ./src/PokerLeagueManager.UI.Web/angular
      
    - name: Generate TypeScript Lib
      run: GenerateTypeScript.bat
      working-directory: ./src/PokerLeagueManager.UI.Web
      shell: cmd
      
    - name: Build Angular
      run: npm run build-prod
      working-directory: ./src/PokerLeagueManager.UI.Web/angular
      
    - name: Create index.cshtml
      run: ./deploy/TransformIndex.ps1 -SourcePath ./src/PokerLeagueManager.UI.Web/angular/dist/index.html -TargetPath ./src/PokerLeagueManager.UI.Web/angular/dist/index.cshtml
      shell: powershell
    
    - name: Run Jasmine Tests
      run: npm run test-prod
      working-directory: ./src/PokerLeagueManager.UI.Web/angular
    
    - name: Build UI.Web
      run: msbuild ./src/PokerLeagueManager.UI.Web/PokerLeagueManager.UI.Web.csproj /p:TreatWarningsAsErrors=true /p:CodeAnalysisRuleSet="../PokerLeagueManager.ruleset" /p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:ValidateArchitecture=true /p:"platform=$env:BuildPlatform" /p:configuration="$env:BuildConfiguration"

    - name: Publish UI.Web Artifacts
      uses: actions/upload-artifact@v1.0.0
      with:
        name: UI.Web
        path: src/PokerLeagueManager.UI.Web/obj/Release/Package/PokerLeagueManager.UI.Web.zip

{'fraction_non_alphanumeric': 0.1002710027100271, 'fraction_numerical': 0.009434909163906454, 'mean_word_length': 2.768532526475038, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1527661', 'n_tokens_mistral': 3287, 'n_tokens_neox': 3166, 'n_words': 588}