mirror of
https://github.com/barkeser2002/ripcord-fix.git
synced 2026-09-25 01:09:53 +03:00
70 lines
2.0 KiB
YAML
70 lines
2.0 KiB
YAML
name: Code Quality
|
|
|
|
on:
|
|
push:
|
|
branches: [ "**" ]
|
|
pull_request:
|
|
branches: [ "**" ]
|
|
schedule:
|
|
# Run weekly on Sundays at 00:00 UTC
|
|
- cron: '0 0 * * 0'
|
|
|
|
jobs:
|
|
clang-format:
|
|
name: Clang Format Check
|
|
runs-on: windows-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Install clang-format
|
|
run: choco install llvm -y
|
|
shell: powershell
|
|
|
|
- name: Run clang-format check
|
|
run: |
|
|
echo Checking code formatting with clang-format...
|
|
clang-format --version
|
|
clang-format --dry-run --Werror --style=file source/*.c source/*.h source/ext/minhook/src/*.c source/ext/minhook/src/*.h source/ext/minhook/include/*.h
|
|
shell: bash
|
|
|
|
cppcheck:
|
|
name: Cppcheck Static Analysis
|
|
runs-on: windows-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Install cppcheck
|
|
run: choco install cppcheck -y
|
|
shell: powershell
|
|
|
|
- name: Run cppcheck
|
|
run: |
|
|
cppcheck --version
|
|
cppcheck --enable=all --inconclusive --quiet --language=c --std=c17 --suppress=missingIncludeSystem --suppress=unusedFunction --include=source/ext/minhook/include/MinHook.h -I source/ -I source/ext/minhook/include/ -I source/ext/minhook/src/ source/*.c source/ext/minhook/src/*.c 2>&1
|
|
shell: bash
|
|
continue-on-error: true
|
|
|
|
msbuild-analyze:
|
|
name: MSVC Static Analysis
|
|
runs-on: windows-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup Visual Studio Developer Command Prompt
|
|
uses: ilammy/msvc-dev-cmd@v1
|
|
with:
|
|
arch: x64
|
|
|
|
- name: Run MSVC with static analysis
|
|
run: |
|
|
echo Running MSVC with static analysis flags...
|
|
cl.exe /analyze /EHsc /nologo /std:c17 /D_CRT_SECURE_NO_WARNINGS /I source/ /I source/ext/ source/*.c 2>&1 || echo Static analysis completed with warnings
|
|
shell: cmd
|
|
continue-on-error: true
|