Download the PHP package spaze/phpcs-phar without Composer

On this page you can find all versions of the php package spaze/phpcs-phar. 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 phpcs-phar

PHP_CodeSniffer phar releases

Create a phar release PHP Tests

This repo contains phar releases of PHPCSStandards/PHP_CodeSniffer.

The files are downloaded from the PHP_CodeSniffer release pages, and if changed, they're commited and a release is created with the same version number as the upstream release.

The whole thing is powered by a GitHub Actions workflow.

I have created this for my personal usage to overcome the performance issues of the 9P filesystem as used by WSL2. The PHPCSStandards organization is also planning to create a Composer phar release so this repository will cease to exist one day, either when the official Composer phar is released, or when the 9P performace is sufficient, or when I retire. Consider yourself warned.

Installation

Install with Composer:

Installing coding standards

The phar releases in this repository do not work with the PHP_CodeSniffer Standards Composer Installer Plugin (the dealerdirect/phpcodesniffer-composer-installer package). Be warned that this package even replaces the installer plugin in its composer.json.

There are several reasons for that:

  1. The installer plugin looks for a different installed package, squizlabs/php_codesniffer to add more standards to
  2. The plugin creates a configuration file with a relative path to the standard being installed, so the code sniffer then expects the standard to be present inside the phar file, which is not the case

However, there are multiple different ways to install a standard. Let's say you want to add slevomat/coding-standard, you can:

Auto-install the available standards

If the CodeSniffer.conf file doesn't exist, this package will find and auto-install all available coding standards on each execution. The altered configuration is not persisted, no config file will be created, because it would be removed on each package update anyway. This is the recommended option emulating the Standards Composer Installer Plugin to a certain point.

Modify the config file

  1. In your project, run

  2. Locate the CodeSniffer.conf file in your vendor/spaze/phpcs-phar directory
  3. Edit the path to the installed standard and make it an absolute path, for example change

    to

Please be aware that the CodeSniffer.conf file will be removed on each package update.

Install the standard using an absolute path

In your project, run

or use any absolute path for the installed_paths value.

Please be aware that the CodeSniffer.conf file will be removed on each package update.


All versions of phpcs-phar with dependencies

PHP Build Version
Package Version
Requires composer-runtime-api Version ^2.1
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 spaze/phpcs-phar contains the following files

Loading the files please wait ....