Download the PHP package nochso/phormat without Composer

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

nochso/phormat

write me to read me License Latest tag on Github Travis CI build status Coverage status

Phormat formats PHP source code.

Differences to other fixers or PSR2:

Introduction, goals and scope

Phormat is a pretty printer based on nikic/php-parser. It discards any formatting and prints source code in a uniform style. Custom formatting options are out of scope.

The chosen style is personal preference and attempts to keep the line count low while keeping the code readable.

You're anti-PSR! Why do you hate FIG?

I'm not. I don't. This is not a replacement, improvement or critique of PSR2 but merely an alternative you're free to ignore.

PSR2 is quite widespread for a reason and has helped lots of projects decide on a common style. However it does not mean everybody loves it personally or that it is a de-facto standard you must adhere to. The questions of tabs vs. spaces or placement of braces will always be part of a holy war as it comes down to personal preference.

In the end, it's best for collaboration if a project has a well defined style that is easy for contributors to adhere to. Which is easily possible for both PSR2 and phormat.

See php-cs-fixer for a great way to adhere to PSR2.

Requirements

This project is written for and tested with PHP 5.6, 7.0 and HHVM.

Installation

For end-users the PHAR version is preferred. To install it globally:

  1. Download the PHAR file from the latest release.
  2. Make it executable: chmod +x phormat.phar
  3. Move it somewhere within your PATH: sudo cp phormat.phar /usr/local/bin/phormat

As local Composer development dependency per project:

As global Composer dependency:

Usage

As a local dependency php vendor/bin/phormat or if installed globally just phormat.

phormat [options] <path>
phormat [options] <path1> <path2> ...

By default PHP files from the specified paths will be overwritten. See the options below to override this behaviour.

If path is a folder it will be searched recursively for files ending with *.php.

Native PHP templates will be skipped to avoid messing up their formatting. Templates are detected by looking for alternative syntax for control structures like if (true): .. endif;

Command line options

Contributing

Feedback, bug reports and pull requests are always welcome.

Please read the contributing guide for instructions.

Change log

See CHANGELOG.md for the full history of changes between releases.

[Unreleased]

Changed

[0.1.5] - 2016-04-23

Changed

[0.1.4] - 2016-04-23

Added

Changed

License

This project is released under the MIT license. See LICENSE.md for the full text.


All versions of phormat with dependencies

PHP Build Version
Package Version
Requires php Version ^5.6 || ^7.0
aura/cli Version ^2.1
nikic/php-parser Version ^2.1.0
nette/finder Version ^2.3
nochso/diff Version dev-master
nochso/omni Version ^0.3.7
padraic/phar-updater Version ^1.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 nochso/phormat contains the following files

Loading the files please wait ....