Skip to content

Commit

Permalink
Merge pull request #144 from shivammathur/develop
Browse files Browse the repository at this point in the history
1.7.1
  • Loading branch information
shivammathur authored Jan 8, 2020
2 parents 7b8bf7a + 16d1cd4 commit 71db1e2
Show file tree
Hide file tree
Showing 35 changed files with 1,411 additions and 377 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/experimental-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
php-versions: ['8.0']
steps:
- name: Checkout
uses: actions/checkout@v1
uses: actions/checkout@v2
with:
fetch-depth: 1

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
php-versions: ['5.6', '7.0', '7.1', '7.2', '7.3', '7.4']
steps:
- name: Checkout
uses: actions/checkout@v1
uses: actions/checkout@v2
with:
fetch-depth: 1

Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

The MIT License (MIT)

Copyright (c) 2019 shivammathur and contributors
Copyright (c) 2019-2020 shivammathur and contributors

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
29 changes: 23 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@ Setup PHP with required extensions, php.ini configuration, code-coverage support

## :wrench: Tools Support

The latest version of the following tools can be setup globally using the `tools` input.
These tools can be setup globally using the `tools` input.

`composer`, `codeception`, `deployer`, `pecl`, `phinx`, `phpcbf`, `phpcpd`, `php-cs-fixer`, `phpcs`, `phpmd`, `phpstan`, `phpunit`, `prestissimo`, `psalm`
`codeception`, `composer`, `composer-prefetcher`, `deployer`, `pecl`, `phinx`, `phpcbf`, `phpcpd`, `php-cs-fixer`, `phpcs`, `phpmd`, `phpstan`, `phpunit`, `prestissimo`, `psalm`

```yaml
uses: shivammathur/setup-php@v1
Expand All @@ -81,7 +81,21 @@ with:
tools: php-cs-fixer, phpunit
```
**Note:** `composer` is setup by default, so that is not required to be specified.
To setup a particular version of a tool, specify it in the form `tool:version`.
Version should be in semver format and a valid release of the tool.

```yaml
uses: shivammathur/setup-php@v1
with:
php-version: '7.4'
tools: php-cs-fixer:2.15.5, phpunit:8.5.1
```

**Note**
- `composer` is setup by default.
- Specifying version for `composer` and `pecl` has no effect, latest version of both tools will be setup.
- If the version specified for the tool is not in semver format, latest version of the tool will be setup.
- Tools which cannot be installed gracefully leave an error message in the logs, the action is not interrupted.

## :signal_strength: Coverage support

Expand Down Expand Up @@ -148,7 +162,7 @@ See [action.yml](action.yml "Metadata for this GitHub Action") and usage below f
```yaml
steps:
- name: Checkout
uses: actions/checkout@v1
uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v1
Expand All @@ -175,7 +189,7 @@ jobs:
name: PHP ${{ matrix.php-versions }} Test on ${{ matrix.operating-system }}
steps:
- name: Checkout
uses: actions/checkout@v1
uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v1
Expand All @@ -200,7 +214,7 @@ jobs:
```yaml
steps:
- name: Checkout
uses: actions/checkout@v1
uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v1
Expand Down Expand Up @@ -255,6 +269,9 @@ Examples for setting up this GitHub Action with different PHP Frameworks/Package

|Framework/Package|Runs on|Workflow|
|--- |--- |--- |
|CakePHP with `MySQL` and `Redis`|`ubuntu`|[cakephp-mysql.yml](./examples/cakephp-mysql.yml "GitHub Action for CakePHP with MySQL and Redis")|
|CakePHP with `PostgreSQL` and `Redis`|`ubuntu`|[cakephp-postgres.yml](./examples/cakephp-postgres.yml "GitHub Action for CakePHP with Postgres and Redis")|
|CakePHP without services|`macOS`, `ubuntu` and `windows`|[cakephp.yml](./examples/cakephp.yml "GitHub Action for CakePHP without services")|
|CodeIgniter|`macOS`, `ubuntu` and `windows`|[codeigniter.yml](./examples/codeigniter.yml "GitHub Action for CodeIgniter")|
|Laravel with `MySQL` and `Redis`|`ubuntu`|[laravel-mysql.yml](./examples/laravel-mysql.yml "GitHub Action for Laravel with MySQL and Redis")|
|Laravel with `PostgreSQL` and `Redis`|`ubuntu`|[laravel-postgres.yml](./examples/laravel-postgres.yml "GitHub Action for Laravel with PostgreSQL and Redis")|
Expand Down
Loading

0 comments on commit 71db1e2

Please sign in to comment.