Skip to content

Test development continuous integration pipeline. Made for Medium post.

Notifications You must be signed in to change notification settings

drinksandco/dev-ci-pipeline-skeleton

Repository files navigation

Development Continuous Integration Pipeline Skeleton

This is the example repository for our post on Medium about "Strict Development CI for PHP".

Requirements

  • PHP >=8.1
  • Composer Package Manager

Installation

git clone [email protected]:drinksandco/dev-ci-pipeline-skeleton.git example
cd example
composer install
composer list

Some new commands should be added to your composer scripts:

  • check-all: Executes all checks
  • precommit-check: Executes all checks required before commit
  • cs-check: Checks PSR-12 coding standard with ECS - Pre-commit check
  • cs-fix: Fixes issues with PSR-12 coding standard
  • inspect: Static analysis with PHPStan - Pre-commit check
  • test: Unit tests using PHPUnit - Pre-commit check
  • psalm: Static analysis with Psalm - Pre-commit check
  • infection: Mutation testing using Infection
  • rector: Automated refactoring using Rector
  • rector-check: Check possible changes for automated refactoring using Rector

Usage

When you install dependencies by composer, GrumPHP registers a precommit-hook in your local git. It will run "precommit-check" command before committing your code locally. Also, you can run any of registered commands using composer.

About

Test development continuous integration pipeline. Made for Medium post.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages