Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@
/phpstan-baseline.neon export-ignore
/phpunit.xml export-ignore
/CLAUDE.md export-ignore
collision-detector.json export-ignore
26 changes: 26 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -317,3 +317,29 @@
with:
path: ./tmp
key: "result-cache-v1-${{ matrix.php-version }}-${{ github.run_id }}"

name-collision:
name: "Name Collision Detector"

runs-on: "ubuntu-latest"
timeout-minutes: 60

steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@5ef0c079ce82195b2a36a210272d6b661572d83e # v2.14.2

Check warning

Code scanning / zizmor

action has a known vulnerability Warning

action has a known vulnerability

Check warning

Code scanning / zizmor

action has a known vulnerability Warning

action has a known vulnerability
with:
egress-policy: audit

- name: "Checkout"
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1

Check warning

Code scanning / zizmor

credential persistence through GitHub Actions artifacts Warning

credential persistence through GitHub Actions artifacts
Comment on lines +333 to +334

- name: "Install PHP"
uses: "shivammathur/setup-php@44454db4f0199b8b9685a5d763dc37cbf79108e1" # v2

Check warning

Code scanning / zizmor

detects commit SHAs that don't match their version comment tags Warning

detects commit SHAs that don't match their version comment tags
with:
coverage: "none"
php-version: "8.5"

- uses: "ramsey/composer-install@3cf229dc2919194e9e36783941438d17239e8520" # v3

Check warning

Code scanning / zizmor

detects commit SHAs that don't match their version comment tags Warning

detects commit SHAs that don't match their version comment tags

- name: "Name Collision Detector"
run: "make name-collision"
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,6 @@ phpstan:
.PHONY: phpstan-generate-baseline
phpstan-generate-baseline:
php vendor/bin/phpstan analyse -c phpstan.neon -b phpstan-baseline.neon

name-collision:
php vendor/bin/detect-collisions --configuration collision-detector.json
3 changes: 3 additions & 0 deletions collision-detector.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"scanPaths": ["src", "tests"]
}
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"php-parallel-lint/php-parallel-lint": "^1.2",
"phpstan/phpstan-deprecation-rules": "^2.0",
"phpstan/phpstan-strict-rules": "^2.0",
"phpunit/phpunit": "^9.6"
"phpunit/phpunit": "^9.6",
"shipmonk/name-collision-detector": "^2.1"
},
"config": {
"sort-packages": true
Expand Down
Loading