mirror of
https://github.com/permissionlesstech/bitchat.git
synced 2026-11-29 08:29:22 +00:00
55 lines
1.6 KiB
YAML
55 lines
1.6 KiB
YAML
name: Dead Code
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
paths-ignore:
|
|
- "**.md"
|
|
- "docs/**"
|
|
- "plans/**"
|
|
- "LICENSE"
|
|
pull_request:
|
|
paths-ignore:
|
|
- "**.md"
|
|
- "docs/**"
|
|
- "plans/**"
|
|
- "LICENSE"
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
concurrency:
|
|
group: periphery-${{ github.event.pull_request.number || github.ref }}
|
|
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
|
|
|
|
jobs:
|
|
periphery:
|
|
name: Periphery scan
|
|
runs-on: macos-latest
|
|
timeout-minutes: 30
|
|
# Blocking, like SwiftLint since #1646. The baseline (committed July 8)
|
|
# has been stable across a month of merges — the "drop continue-on-error
|
|
# once the baseline proves stable" condition this job shipped with is met.
|
|
# Known macOS-scan false positives stay suppressed by the baseline; only
|
|
# NEW dead code fails the job (--strict below).
|
|
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- name: Install Periphery
|
|
# homebrew-core formula; the peripheryapp tap lags years behind.
|
|
env:
|
|
HOMEBREW_NO_AUTO_UPDATE: "1"
|
|
HOMEBREW_NO_INSTALL_CLEANUP: "1"
|
|
run: brew install periphery
|
|
|
|
- name: Scan for dead code
|
|
# Config comes from .periphery.yml; known findings (mostly iOS-only
|
|
# code invisible to a macOS scan) are suppressed by the committed
|
|
# baseline. --strict fails the step when NEW dead code appears.
|
|
run: periphery scan --strict --disable-update-check
|