chore: Sync MokoStandards workflows and configurations (#85)
* chore: update LICENSE from MokoStandards * chore: add update.xml from MokoStandards * chore: update phpstan.neon from MokoStandards * chore: add Makefile from MokoStandards * chore: update .gitignore from MokoStandards * chore: add composer.json from MokoStandards * chore: add .moko-standards from MokoStandards * chore: update .github/copilot.yml from MokoStandards * chore: update .github/copilot-instructions.md from MokoStandards * chore: update .github/CLAUDE.md from MokoStandards * chore: add .github/workflows/codeql-analysis.yml from MokoStandards * chore: add .github/workflows/standards-compliance.yml from MokoStandards * chore: add .github/workflows/enterprise-firewall-setup.yml from MokoStandards * chore: add .github/workflows/deploy-dev.yml from MokoStandards * chore: add .github/ISSUE_TEMPLATE/config.yml from MokoStandards * chore: add .github/ISSUE_TEMPLATE/adr.md from MokoStandards * chore: add .github/ISSUE_TEMPLATE/bug_report.md from MokoStandards * chore: add .github/ISSUE_TEMPLATE/documentation.md from MokoStandards * chore: add .github/ISSUE_TEMPLATE/enterprise_support.md from MokoStandards * chore: add .github/ISSUE_TEMPLATE/feature_request.md from MokoStandards * chore: add .github/ISSUE_TEMPLATE/firewall-request.md from MokoStandards * chore: add .github/ISSUE_TEMPLATE/question.md from MokoStandards * chore: add .github/ISSUE_TEMPLATE/request-license.md from MokoStandards * chore: add .github/ISSUE_TEMPLATE/rfc.md from MokoStandards * chore: add .github/ISSUE_TEMPLATE/security.md from MokoStandards * chore: add .github/ISSUE_TEMPLATE/joomla_issue.md from MokoStandards
This commit was merged in pull request #85.
This commit is contained in:
57
phpstan.neon
57
phpstan.neon
@@ -1,37 +1,32 @@
|
||||
# Copyright (C) 2026 Moko Consulting <hello@mokoconsulting.tech>
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
#
|
||||
# PHPStan configuration for Joomla extension repositories.
|
||||
# Extends the base MokoStandards config and adds Joomla framework class stubs
|
||||
# so PHPStan can resolve Factory, CMSApplication, User, Table, etc.
|
||||
# without requiring a full Joomla installation.
|
||||
|
||||
parameters:
|
||||
level: 5
|
||||
|
||||
paths:
|
||||
- src
|
||||
|
||||
# Exclude paths
|
||||
|
||||
excludePaths:
|
||||
- src/vendor/*
|
||||
- src/node_modules/*
|
||||
- src/cache/*
|
||||
- src/tmp/*
|
||||
|
||||
# Scan files
|
||||
scanFiles:
|
||||
- src/templates/index.php
|
||||
- src/templates/component.php
|
||||
- src/templates/error.php
|
||||
- src/templates/offline.php
|
||||
|
||||
# Report unmatched ignored errors
|
||||
reportUnmatchedIgnoredErrors: false
|
||||
|
||||
# Check function name case
|
||||
checkFunctionNameCase: true
|
||||
|
||||
# Check internal classes
|
||||
checkInternalClassCaseSensitivity: true
|
||||
|
||||
# Treat PHP version
|
||||
phpVersion: 80000
|
||||
|
||||
# Ignore errors - adjust as needed
|
||||
- vendor
|
||||
- node_modules
|
||||
|
||||
# Joomla framework stubs — resolved via the enterprise package from vendor/
|
||||
stubFiles:
|
||||
- vendor/mokoconsulting-tech/enterprise/templates/stubs/joomla.php
|
||||
|
||||
# Suppress errors that are structural in Joomla's service-container architecture
|
||||
ignoreErrors:
|
||||
# Allow dynamic properties which are common in Joomla
|
||||
- '#Access to an undefined property#'
|
||||
# Allow some reflection usage
|
||||
- '#Call to an undefined static method#'
|
||||
# Joomla's service-based dependency injection returns mixed from getApplication()
|
||||
- '#Cannot call method .+ on Joomla\\CMS\\Application\\CMSApplication\|null#'
|
||||
# Factory::getX() patterns are safe at runtime even when nullable in stubs
|
||||
- '#Call to static method [a-zA-Z]+\(\) on an interface#'
|
||||
|
||||
reportUnmatchedIgnoredErrors: false
|
||||
checkMissingIterableValueType: false
|
||||
checkGenericClassInNonGenericObjectType: false
|
||||
|
||||
Reference in New Issue
Block a user