Download the PHP package marac19901990/php-quality-pack without Composer

On this page you can find all versions of the php package marac19901990/php-quality-pack. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package php-quality-pack

PHP Quality Pack

CI Packagist Version PHP Version License

Zero-config PHP code quality standards with GrumPHP, PHPStan, and PHP-CS-Fixer. Installs pre-commit hooks that automatically run static analysis and code style fixes on every commit.

What It Does

Default Standards

Tool Configuration
PHPStan Level 5, strict rules, deprecation warnings, bleeding edge
PHP-CS-Fixer PER-CS, PHP 8.2 migration, sorted imports, trailing commas, single quotes
PHP Version 8.2+ required

Requirements

This package intentionally requires modern versions:

Legacy projects requiring older versions should not use this pack.

Note: All dependencies use stable releases. If your project has "minimum-stability": "stable" (the default), installation will work without issues.

Installation

Setup

1. Update composer.json

Add the following to your project's composer.json:

2. Create a PHPStan baseline file

IMPORTANT: This file is required. PHPStan will fail without it.

Create an empty phpstan-baseline.neon in your project root:

Or generate one with current errors (recommended for existing codebases):

3. Run composer install

That's it! GrumPHP hooks are automatically installed.

Usage

Just commit

PHPStan and PHP-CS-Fixer run automatically on changed files. If there are issues, the commit is blocked until you fix them.

Manual checks

Regenerate baseline

When you've fixed PHPStan errors or want to capture existing ones:

Customization

For most projects, the default configuration works out of the box. Only customize if you have specific needs.

Override GrumPHP tasks

Create a local grumphp.yml in your project root:

Then update config-default-path in composer.json:

Add additional PHPStan paths or ignores

Create a local phpstan.neon:

Then create a grumphp.yml that points to your local config.

Adding framework-specific extensions

This package includes only base PHPStan extensions. Add framework-specific extensions to your project:

The phpstan/extension-installer automatically registers these extensions.

Two Usage Models

1. Direct Use (Generic Defaults)

Use directly via composer require if you're happy with:

Good for: personal projects, new projects, teams aligned with these standards.

2. Fork and Customize

Fork this repo to create your organization's version:

  1. Fork to your-org/php-quality-pack
  2. Modify rules/ files to your standards:
    • Change PHPStan level in rules/phpstan.neon
    • Adjust PHP-CS-Fixer rules in rules/php-cs-fixer.php
    • Add/remove GrumPHP tasks in rules/grumphp.yml
  3. Update paths in rules/grumphp.yml to your vendor name
  4. Publish to Packagist as your org's package

Good for: organizations with specific coding standards.

Default Configuration Details

PHPStan (rules/phpstan.neon)

PHP-CS-Fixer (rules/php-cs-fixer.php)

All rules are non-risky (safe transformations that don't change code behavior).

GrumPHP (rules/grumphp.yml)

Migration from Local Configs

If your project has local phpstan.neon, grumphp.yml, or .php-cs-fixer.dist.php:

  1. Regenerate baseline: Run vendor/bin/phpstan analyse src/ -c vendor/marac19901990/php-quality-pack/rules/phpstan.neon --generate-baseline
  2. Delete local configs: Remove phpstan.neon, grumphp.yml, .php-cs-fixer.dist.php
  3. Update composer.json: Set config-default-path to vendor/marac19901990/php-quality-pack/rules/grumphp.yml
  4. Run composer install: Reinstalls GrumPHP hooks with new config

Makefile Updates

If your project uses Makefile targets, update them to use the vendor config paths:

Recommended .gitignore

Add these entries to your project's .gitignore:

GitHub Actions

Example workflow for CI:

Known Issues

Deprecation warning during commits

You may see this warning during commits:

This comes from gitonomy/gitlib (a GrumPHP dependency) and doesn't affect functionality. It will be resolved when GrumPHP updates the dependency.

License

MIT License - see LICENSE for details.


All versions of php-quality-pack with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
phpro/grumphp Version ^1.0 || ^2.0
friendsofphp/php-cs-fixer Version ^3.1
phpstan/phpstan Version ^2.0
phpstan/extension-installer Version ^1.4
phpstan/phpstan-deprecation-rules Version ^2.0
phpstan/phpstan-strict-rules Version ^2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package marac19901990/php-quality-pack contains the following files

Loading the files please wait ...