Skip to content

Commit

Permalink
Add formatter Ci files
Browse files Browse the repository at this point in the history
  • Loading branch information
Kiuh committed Nov 11, 2023
1 parent 3ef53a7 commit ed03c58
Show file tree
Hide file tree
Showing 3 changed files with 102 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/activation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Acquire activation file
on:
workflow_dispatch: {}
jobs:
activation:
name: Request manual activation file 🔑
runs-on: ubuntu-latest
steps:
# Request manual activation file
- name: Request manual activation file
id: getManualLicenseFile
uses: game-ci/unity-request-activation-file@v2
# Upload artifact (Unity_v20XX.X.XXXX.alf)
- name: Expose as artifact
uses: actions/upload-artifact@v2
with:
name: ${{ steps.getManualLicenseFile.outputs.filePath }}
path: ${{ steps.getManualLicenseFile.outputs.filePath }}

38 changes: 38 additions & 0 deletions .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Build Test

on: [push, pull_request]
# push:
# branches:
# - 'main'

jobs:
buildForAllSupportedPlatforms:
name: Build for ${{ matrix.targetPlatform }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
targetPlatform:
- StandaloneWindows # Build a Windows standalone.
- StandaloneWindows64 # Build a Windows 64-bit standalone.
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
lfs: true
- uses: actions/cache@v3
with:
path: Library
key: Library-${{ matrix.targetPlatform }}
restore-keys: Library-
- uses: game-ci/unity-builder@v3
env:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
with:
targetPlatform: ${{ matrix.targetPlatform }}
- uses: actions/upload-artifact@v3
with:
name: Build-${{ matrix.targetPlatform }}
path: build/${{ matrix.targetPlatform }}
45 changes: 45 additions & 0 deletions .github/workflows/dotnet-format.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: dotnet format

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

jobs:
check-format-dotnet:
runs-on: windows-latest

steps:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: '5.0.x'

- name: Install dotnet-format tool
run: dotnet tool install -g dotnet-format

- name: Check out code
uses: actions/checkout@v2

- name: Run dotnet format
run: dotnet format '.\' --folder --check --verbosity diagnostic

check-format-cscharpier:
runs-on: windows-latest

steps:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: '6.0.x'

- name: Install csharpier tool
run: dotnet tool install csharpier -g

- name: Check out code
uses: actions/checkout@v2

- name: Run csharpier format
run: dotnet csharpier '.\Assets\' --check

0 comments on commit ed03c58

Please sign in to comment.