Skip to content

Standardize File Handling with std::filesystem and Expand Cross-Platform Utilities #319

Standardize File Handling with std::filesystem and Expand Cross-Platform Utilities

Standardize File Handling with std::filesystem and Expand Cross-Platform Utilities #319

Workflow file for this run

name: PR Checks
on:
pull_request:
branches: [master]
types: [push, opened, ready_for_review]
workflow_dispatch:
jobs:
pr-checks:
name: Check lint
runs-on: windows-latest
if: github.event.pull_request.draft == false
steps:
- name: Checkout git repository
uses: actions/checkout@v4
- name: Check lint
run: |
New-Item src/vendor/opt/bin -Type Directory -Force
Invoke-WebRequest -Uri https://raw.githubusercontent.com/ko4life-net/ko-vendor/master/opt/bin/clang-format.exe -OutFile src/vendor/opt/bin/clang-format.exe
& .\format.ps1
$git_diff = (git diff --stat -- "*.cpp" "*.CPP" "*.c" "*.C" "*.h" "*.H")
if ($git_diff -ne $null) {
Write-Host "Code formatting issues found! Please run the format.ps1 script, commit the changes and push."
git diff --stat -- "*.cpp" "*.CPP" "*.c" "*.C" "*.h" "*.H"
exit(1)
}