Skip to content

Commit

Permalink
Merge pull request #33 from badges/release/v2
Browse files Browse the repository at this point in the history
Poser v2.0
  • Loading branch information
JellyBellyDev authored Jul 29, 2020
2 parents 4281890 + 895eb98 commit d0827a7
Show file tree
Hide file tree
Showing 51 changed files with 961 additions and 572 deletions.
83 changes: 83 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
version: 2.1

executors:
poser_executor: # declares a reusable executor
docker:
- image: pugx/poser:2.0
working_directory: ~/app

jobs:
checkout_code:
executor: poser_executor
steps:
- checkout
- save_cache:
key: v1-repo-{{ .Environment.CIRCLE_SHA1 }}
paths:
- ~/app

php_dependencies:
executor: poser_executor
steps:
- restore_cache:
keys:
- v1-repo-{{ .Environment.CIRCLE_SHA1 }}
- run:
name: install project dependencies
command: composer install -n --no-progress --no-suggest
- save_cache:
paths:
- ~/app/bin
- ~/app/vendor
key: v1-php-dependencies-{{ .Environment.CIRCLE_SHA1 }}

lint_checks:
executor: poser_executor
steps:
- restore_cache:
keys:
- v1-repo-{{ .Environment.CIRCLE_SHA1 }}
- restore_cache:
name: Restore PHP Dependencies Cache
keys:
- v1-php-dependencies-{{ .Environment.CIRCLE_SHA1 }}
- run:
name: run php-cs-fixer checks
command: bin/php-cs-fixer fix --verbose --diff --dry-run

phpspec_and_behat:
executor: poser_executor
steps:
- restore_cache:
keys:
- v1-repo-{{ .Environment.CIRCLE_SHA1 }}
- restore_cache:
name: Restore PHP Dependencies Cache
keys:
- v1-php-dependencies-{{ .Environment.CIRCLE_SHA1 }}
- run:
name: run phpspec tests
command: bin/phpspec run --format=pretty
- run:
name: run phpspec coverage tests
command: bin/phpspec run -f progress -c phpspec-coverage.yml
- store_artifacts:
path: coverage
- run:
name: run behat checks
command: bin/behat

workflows:
version: 2
build-and-test:
jobs:
- checkout_code
- php_dependencies:
requires:
- checkout_code
- lint_checks:
requires:
- php_dependencies
- phpspec_and_behat:
requires:
- php_dependencies
17 changes: 17 additions & 0 deletions .circleci/images/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
FROM circleci/php:7.4-fpm-browsers

USER root

# install system packages
RUN apt-get install -qqy libzip-dev libpng-dev libjpeg-dev libfreetype6-dev

# configure php packages
RUN docker-php-ext-configure gd --with-freetype=/usr/include/ --with-jpeg=/usr/include/

# install php requirements
RUN docker-php-ext-install zip iconv gd

USER circleci

# install prestissimo
RUN composer global require hirak/prestissimo
2 changes: 2 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
custom: "https://paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=ETT4JRJARLTSC"
github: [JellyBellyDev, AlessandroMinoccheri]
34 changes: 34 additions & 0 deletions .github/ISSUE_TEMPLATE/BC_Break.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
name: 💥 BC Break
about: Have you encountered an issue during upgrade? 💣
---

### BC Break Report

<!-- Fill in the relevant information below to help triage your issue. -->

| Q | A
|------------ | ------
| BC Break | yes
| Version | x.y.z

#### Summary

<!-- Provide a summary describing the problem you are experiencing. -->

#### Previous behavior

<!-- What was the previous (working) behavior? -->

#### Current behavior

<!-- What is the current (broken) behavior? -->

#### How to reproduce

<!--
Provide steps to reproduce the BC break.
If possible, also add a code snippet.
Adding a failing Unit or Functional Test would help us a lot - you can submit it in a Pull Request separately, referencing this bug report.
-->

34 changes: 34 additions & 0 deletions .github/ISSUE_TEMPLATE/Bug.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
name: 🐞 Bug Report
about: Something is broken? 🔨
---

### Bug Report

<!-- Fill in the relevant information below to help triage your issue. -->

| Q | A
|---------------- | ------
| BC Break | yes/no
| Library Version | x.y.z <!-- provide patch version too -->
| PHP version | x.y.z

#### Summary

<!-- Provide a summary describing the problem you are experiencing. -->

#### Current behavior

<!-- What is the current (buggy) behavior? -->

#### How to reproduce

<!--
Provide steps to reproduce the bug.
If possible, also add a code snippet.
Adding a failing Unit or Functional Test would help us a lot - you can submit one in a Pull Request separately, referencing this bug report.
-->

#### Expected behavior

<!-- What was the expected (correct) behavior? -->
19 changes: 19 additions & 0 deletions .github/ISSUE_TEMPLATE/Feature_Request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
name: 🎉 Feature Request
about: You have a neat idea that should be implemented? 🎩
---

### Feature Request

<!-- Fill in the relevant information below to help triage your issue. -->

| Q | A
|------------ | ------
| New Feature | yes
| RFC | yes/no
| BC Break | yes/no

#### Summary

<!-- Provide a summary of the feature you would like to see implemented. -->

22 changes: 22 additions & 0 deletions .github/ISSUE_TEMPLATE/Support_Question.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
name: ❓ Support Question
about: Have a problem that you can't figure out? 🤔
---

<!-- Fill in the relevant information below to help triage your issue. -->

| Q | A
|---------------- | ------
| Library version | x.y.z <!-- provide patch version too -->
| PHP version | x.y.z


<!--
Keep in mind that GitHub is primarily an issue tracker.
Also, look in old issues (open and/or closed) too see if issue has been
previously discussed.
-->

### Support Question

<!-- Describe the issue you are facing here. -->
19 changes: 19 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE/Improvement.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
name: ⚙ Improvement
about: You have some improvement to make badge-poser better? 🎁
---

### Improvement

<!-- Fill in the relevant information below to help triage your issue. -->

| Q | A
|------------ | ------
| New Feature | yes
| RFC | yes/no
| BC Break | yes/no
| Issue | Close #...

#### Summary

<!-- Provide a summary of the improvement you are submitting. -->
24 changes: 24 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE/New_Feature.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
name: 🎉 New Feature
about: You have implemented some neat idea that you want to make part of badge-poser? 🎩
---

<!--
Thank you for submitting new feature!
-->

### New Feature

<!-- Fill in the relevant information below to help triage your issue. -->

| Q | A
|------------ | ------
| New Feature | yes
| RFC | yes/no
| BC Break | yes/no
| Issue | Close #...

#### Summary

<!-- Provide a summary of the feature you have implemented. -->

4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
/bin/behat
/bin/php-cs-fixer
/bin/phpspec
/bin/yaml-lint
/coverage
/vendor
.php_cs.cache
composer.lock
docker-compose.yml
29 changes: 29 additions & 0 deletions .php_cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<?php
// see https://github.com/FriendsOfPHP/PHP-CS-Fixer

$finder = PhpCsFixer\Finder::create()
->in(__DIR__)
->exclude(['vendor'])
;

return PhpCsFixer\Config::create()
->setRiskyAllowed(true)
->setRules([
'@Symfony' => true,
'@Symfony:risky' => true,
'@PHP71Migration:risky' => true,
'@PHPUnit60Migration:risky' => true,
'array_syntax' => ['syntax' => 'short'],
'ordered_imports' => true,
'declare_strict_types' => false,
'native_function_invocation' => true,
'concat_space' => ['spacing' => 'one'],
'binary_operator_spaces' => ['align_double_arrow' => true, 'align_equals' => true],
'single_blank_line_at_eof' => true,
'phpdoc_align' => ['align' => 'vertical'],
'phpdoc_separation' => true,
'phpdoc_summary' => false,
'random_api_migration' => true,
])
->setFinder($finder)
;
23 changes: 0 additions & 23 deletions .scrutinizer.yml

This file was deleted.

38 changes: 0 additions & 38 deletions .travis.yml

This file was deleted.

Loading

0 comments on commit d0827a7

Please sign in to comment.