Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
127 changes: 63 additions & 64 deletions .github/workflows/build_artifacts.yml
Original file line number Diff line number Diff line change
@@ -1,75 +1,74 @@
name: Build Artifacts

on:
workflow_call:
inputs:
build-configuration:
default: 'Release'
required: false
type: string
mdix-version:
required: true
type: string
mdix-colors-version:
required: true
type: string
mdix-mahapps-version:
required: true
type: string

workflow_call:
inputs:
build-configuration:
default: "Release"
required: false
type: string
mdix-version:
required: true
type: string
mdix-colors-version:
required: true
type: string
mdix-mahapps-version:
required: true
type: string

jobs:
build:
name: Build and Test
runs-on: windows-latest
build:
name: Build and Test
runs-on: windows-latest

env:
solution: MaterialDesignToolkit.Full.sln

env:
solution: MaterialDesignToolkit.Full.sln
steps:
- uses: actions/checkout@v4

steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: |
6.x
7.x
8.x

- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: |
6.x
7.x
8.x

- name: Restore dependencies
run: dotnet restore ${{ env.solution }}

- name: Build
run: dotnet build ${{ env.solution }} --configuration ${{ inputs.build-configuration }} --no-restore -p:Platform="Any CPU" -p:TreatWarningsAsErrors=True
env:
MDIXVersion: ${{ inputs.mdix-version }}
MDIXColorsVersion: ${{ inputs.mdix-colors-version }}
MDIXMahAppsVersion: ${{ inputs.mdix-mahapps-version }}

- name: Test
timeout-minutes: 20
run: dotnet test ${{ env.solution }} --configuration ${{ inputs.build-configuration }} --no-build --blame-crash --logger GitHubActions

- name: Upload Screenshots
if: ${{ always() }}
uses: actions/upload-artifact@v4
with:
name: Screenshots-${{ github.run_number }}
path: ${{ github.workspace }}\MaterialDesignThemes.UITests\bin\${{ inputs.build-configuration }}\net8.0-windows7\Screenshots
if-no-files-found: ignore
- name: Restore dependencies
run: dotnet restore ${{ env.solution }}

- name: Build
run: dotnet build ${{ env.solution }} --configuration ${{ inputs.build-configuration }} --no-restore -p:Platform="Any CPU" -p:TreatWarningsAsErrors=True
env:
MDIXVersion: ${{ inputs.mdix-version }}
MDIXColorsVersion: ${{ inputs.mdix-colors-version }}
MDIXMahAppsVersion: ${{ inputs.mdix-mahapps-version }}

- name: Test
timeout-minutes: 20
run: dotnet test ${{ env.solution }} --configuration ${{ inputs.build-configuration }} --no-build --blame-crash --logger GitHubActions

- name: Upload Screenshots
if: ${{ always() }}
uses: actions/upload-artifact@v4
with:
name: Screenshots-${{ github.run_number }}
path: ${{ github.workspace }}tests\MaterialDesignThemes.UITests\bin\${{ inputs.build-configuration }}\net8.0-windows7\Screenshots
if-no-files-found: ignore

- name: Build NuGets
run: .\Scripts\BuildNugets.ps1 -MDIXVersion ${{ inputs.mdix-version }} -MDIXColorsVersion ${{ inputs.mdix-colors-version }} -MDIXMahAppsVersion ${{ inputs.mdix-mahapps-version }}
- name: Build NuGets
run: .\build\BuildNugets.ps1 -MDIXVersion ${{ inputs.mdix-version }} -MDIXColorsVersion ${{ inputs.mdix-colors-version }} -MDIXMahAppsVersion ${{ inputs.mdix-mahapps-version }}

- name: Upload NuGets
uses: actions/upload-artifact@v4
with:
name: NuGets
path: "*.nupkg"
- name: Upload NuGets
uses: actions/upload-artifact@v4
with:
name: NuGets
path: "*.nupkg"

- name: Upload Demo App
uses: actions/upload-artifact@v4
with:
name: DemoApp
path: "MainDemo.Wpf/bin/${{ env.buildConfiguration }}"
- name: Upload Demo App
uses: actions/upload-artifact@v4
with:
name: DemoApp
path: "src/MainDemo.Wpf/bin/${{ env.buildConfiguration }}"
41 changes: 20 additions & 21 deletions .github/workflows/control_styles.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,26 @@
name: Wiki - Update Control Styles

on:
# push:
# branches: [ master ]
workflow_dispatch:
# push:
# branches: [ master ]
workflow_dispatch:

jobs:
build:
build:
runs-on: ubuntu-latest

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Generate Control Styles Markdown
run: Scripts/GenerateThemesWikiMarkdown.ps1
shell: pwsh
- name: Upload Control Styles to Wiki
uses: docker://decathlon/wiki-page-creator-action:latest
env:
GH_PAT: ${{ secrets.SA_TOKEN }}
ACTION_MAIL: [email protected]
ACTION_NAME: Material Design Service Account
OWNER: MaterialDesignInXAML
REPO_NAME: MaterialDesignInXamlToolkit
MD_FOLDER: Scripts
WIKI_PUSH_MESSAGE: Automatic update of ControlStyleList.md from GitHub Action
steps:
- uses: actions/checkout@v4
- name: Generate Control Styles Markdown
run: build/GenerateThemesWikiMarkdown.ps1
shell: pwsh
- name: Upload Control Styles to Wiki
uses: docker://decathlon/wiki-page-creator-action:latest
env:
GH_PAT: ${{ secrets.SA_TOKEN }}
ACTION_MAIL: [email protected]
ACTION_NAME: Material Design Service Account
OWNER: MaterialDesignInXAML
REPO_NAME: MaterialDesignInXamlToolkit
MD_FOLDER: build
WIKI_PUSH_MESSAGE: Automatic update of ControlStyleList.md from GitHub Action
80 changes: 40 additions & 40 deletions .github/workflows/icon_update.yml
Original file line number Diff line number Diff line change
@@ -1,49 +1,49 @@
name: Icon Update

on:
workflow_dispatch:
schedule:
- cron: '0 3 * * *'
workflow_dispatch:
schedule:
- cron: "0 3 * * *"

env:
GH_TOKEN: ${{ secrets.SA_PAT }}
GH_TOKEN: ${{ secrets.SA_PAT }}

defaults:
run:
shell: pwsh
run:
shell: pwsh

jobs:
build:
#This check prevents this from running on forks
if: ${{ github.repository == 'MaterialDesignInXAML/MaterialDesignInXamlToolkit' }}

runs-on: windows-latest

steps:
- uses: actions/checkout@v4

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

- name: Run Icon Generation
run: dotnet run -c Release -- icons
working-directory: ./mdresgen

- name: Check for changes
id: check_for_changes
run: |
$hasChanges = $((git status --porcelain).Length -gt 0).ToString().ToLower()
"has_changes=$hasChanges" >> $env:GITHUB_OUTPUT

- name: Open Pull Request
if: ${{ steps.check_for_changes.outputs.has_changes == 'true' }}
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git checkout -b "automated/icon_update"
git commit -m "[bot] Pack Icon update" --all
git push -f --set-upstream origin automated/icon_update
gh pr create --fill
gh pr merge automated/icon_update --delete-branch --auto --squash
build:
#This check prevents this from running on forks
if: ${{ github.repository == 'MaterialDesignInXAML/MaterialDesignInXamlToolkit' }}

runs-on: windows-latest

steps:
- uses: actions/checkout@v4

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

- name: Run Icon Generation
run: dotnet run -c Release -- icons
working-directory: ./src/MaterialDesignToolkit.ResourceGeneration

- name: Check for changes
id: check_for_changes
run: |
$hasChanges = $((git status --porcelain).Length -gt 0).ToString().ToLower()
"has_changes=$hasChanges" >> $env:GITHUB_OUTPUT

- name: Open Pull Request
if: ${{ steps.check_for_changes.outputs.has_changes == 'true' }}
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git checkout -b "automated/icon_update"
git commit -m "[bot] Pack Icon update" --all
git push -f --set-upstream origin automated/icon_update
gh pr create --fill
gh pr merge automated/icon_update --delete-branch --auto --squash
Loading