Skip to content
This repository has been archived by the owner on Jul 8, 2023. It is now read-only.

Commit

Permalink
Merge branch 'release/3.0.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
ezzatron committed Feb 12, 2016
2 parents 689ebcc + de682c4 commit c9a4c52
Show file tree
Hide file tree
Showing 31 changed files with 1,535 additions and 1,148 deletions.
1 change: 1 addition & 0 deletions .archer/travis.env
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
th+qR2CkDQjUIRPa7apds+yB9oSln5+Xa53Y9V103Uh9cWaKCB5S8Oa351jcBfgDWV2XCe6JKDuK1kAYqTOR1zJaAFuukfbbO0WrxJFC9vVgquT4stekHsScfslWyF0tzTanZif2PwivK6frLketMQwYr1PhhMdZvKMn0s95XcQ=
9 changes: 5 additions & 4 deletions .travis.install → .archer/travis.install
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
#!/usr/bin/env php
<?php

// Update composer to the latest version ...
passthru('composer self-update --no-interaction');

// Build a composer config that uses the GitHub OAuth token if it is available ...
$config = array(
'config' => array(
'notify-on-install' => false
)
'notify-on-install' => false,
),
);

if ($token = getenv('ARCHER_TOKEN')) {
$config['config']['github-oauth'] = array(
'github.com' => $token
'github.com' => $token,
);
$composerFlags = '--prefer-dist';
} else {
Expand All @@ -33,5 +34,5 @@ if ($token) {

// Install composer dependencies ...
$exitCode = 0;
passthru('composer install --dev --no-progress --no-interaction --ansi ' . $composerFlags, $exitCode);
passthru('composer install --dev --no-progress --no-interaction --ignore-platform-reqs --ansi ' . $composerFlags, $exitCode);
exit($exitCode);
File renamed without changes.
4 changes: 2 additions & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
.gitattributes export-ignore
.gitignore export-ignore
.travis.* export-ignore
.archer.* export-ignore
test export-ignore
/.archer/ export-ignore
/test/ export-ignore
# archer end
60 changes: 60 additions & 0 deletions .php_cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
<?php

$finder = Symfony\CS\Finder\DefaultFinder::create()
->in(__DIR__)
->exclude(
array(
'artifacts',
'vendor',
)
);

return Symfony\CS\Config\Config::create()
->level(Symfony\CS\FixerInterface::PSR2_LEVEL)
->fixers(
array(
// symfony
'blankline_after_open_tag',
'duplicate_semicolon',
'extra_empty_lines',
'include',
'join_function',
'list_commas',
'multiline_array_trailing_comma',
'namespace_no_leading_whitespace',
'new_with_braces',
'no_blank_lines_after_class_opening',
'no_empty_lines_after_phpdocs',
'object_operator',
'operators_spaces',
'phpdoc_indent',
'phpdoc_params',
'phpdoc_short_description',
'phpdoc_to_comment',
'phpdoc_trim',
'phpdoc_type_to_var',
'phpdoc_var_without_name',
'pre_increment',
'remove_leading_slash_use',
'remove_lines_between_uses',
'return',
'self_accessor',
'single_array_no_trailing_comma',
'single_blank_line_before_namespace',
'single_quote',
'spaces_before_semicolon',
'spaces_cast',
'standardize_not_equal',
'ternary_spaces',
'trim_array_spaces',
'unary_operators_spaces',
'unused_use',
'whitespacy_lines',

// contrib
'concat_with_spaces',
'multiline_spaces_before_semicolon',
'ordered_use',
)
)
->finder($finder);
1 change: 0 additions & 1 deletion .travis.env

This file was deleted.

13 changes: 7 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
sudo: false
language: php

php: ["5.3", "5.4", "5.5", "5.6", "hhvm"]
php: ["5.3", "5.4", "5.5", "5.6", "7.0", "hhvm"]

matrix:
allow_failures: [{"php": "5.6"}, {"php": "hhvm"}]
allow_failures: [{"php": "hhvm"}]
fast_finish: true

env:
global:
- ARCHER_PUBLISH_VERSION=5.5
- secure: "uwKCMzKTB8sr/BI0G/xwXjncVK4Qqxgld3FFu3bykWg15vQKU2UJ4SnIzy9zP33iX7pMVUaN/J4Anbzl3fyCeKoFgFCvvqxctbmarZ65v2TZ2topiN1aOg95ORTSUsJVETnua08hI2p8UcGhtyLW7FglfG5/uSXb7LGFyXKAovM="
- ARCHER_PUBLISH_VERSION=5.6
- secure: "th+qR2CkDQjUIRPa7apds+yB9oSln5+Xa53Y9V103Uh9cWaKCB5S8Oa351jcBfgDWV2XCe6JKDuK1kAYqTOR1zJaAFuukfbbO0WrxJFC9vVgquT4stekHsScfslWyF0tzTanZif2PwivK6frLketMQwYr1PhhMdZvKMn0s95XcQ="

install:
- ./.travis.install
- ./.archer/travis.install

script:
- ./vendor/bin/archer travis:build
- ./vendor/bin/archer travis:build --ansi
23 changes: 15 additions & 8 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,32 @@
# Composer NPM bridge changelog

## 3.0.0 (2016-02-12)

- **[BC BREAK]** Stripped down implementation, many public methods removed.
- **[FIXED]** Updated Composer API version constraint ([#10]).

[#10]: https://github.com/eloquent/composer-npm-bridge/issues/10

## 2.1.1 (2014-09-08)

- **[IMPROVED]** Support for custom installation paths as determined by Composer
plugins
plugins.

## 2.1.0 (2014-02-12)

- **[IMPROVED]** Composer dev/production modes are now honored when installing
NPM dependencies
NPM dependencies.
- **[IMPROVED]** Can now be utilized as a dev-only dependency of the root
package
package.

## 2.0.0 (2014-01-29)

- **[BC BREAK]** Completely re-written as a Composer plugin
- **[IMPROVED]** Functions without custom Composer script configuration
- **[BC BREAK]** Completely re-written as a Composer plugin.
- **[IMPROVED]** Functions without custom Composer script configuration.

## 1.0.1 (2013-03-04)

- **[NEW]** [Archer] integration
- **[NEW]** Implemented changelog
- **[NEW]** [Archer] integration.
- **[NEW]** Implemented changelog.

[Archer]: (https://github.com/IcecaveStudios/archer)
[archer]: https://github.com/IcecaveStudios/archer
40 changes: 22 additions & 18 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,26 +4,30 @@
community are encouraged. Please take a moment to read these guidelines before
submitting changes.

### Code style
## Code style

All PHP code must adhere to the
[PSR-2](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md)
standards.
All PHP code must adhere to the [PSR-2] standards.

### Branching and pull requests
[psr-2]: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md

## Branching and pull requests

As a guideline, please follow this process:

1. [Fork the repository](https://help.github.com/articles/fork-a-repo).
2. Create a topic branch for the change:
* New features should branch from **develop**.
* Bug fixes to existing versions should branch from **master**.
* Please ensure the branch is clearly labelled as a feature or fix.
3. Make the relevant changes.
4. [Squash](http://git-scm.com/book/en/Git-Tools-Rewriting-History#Changing-Multiple-Commit-Messages)
commits if necessary.
4. Submit a pull request to the **develop** branch.

Please note this is a general guideline only. For more information on the
branching structure please see the
[git-flow cheatsheet](http://danielkummer.github.com/git-flow-cheatsheet/).
1. [Fork the repository].
2. Create a topic branch for the change, branching from **develop**
(`git checkout -b branch-name develop`).
3. Make the relevant changes.
4. [Squash] commits if necessary (`git rebase -i develop`).
5. Submit a pull request to the **develop** branch.

[fork the repository]: https://help.github.com/articles/fork-a-repo
[squash]: http://git-scm.com/book/en/Git-Tools-Rewriting-History#Changing-Multiple-Commit-Messages

## Tests

- Run the tests with `vendor/bin/archer t path/to/tests`, or simply
`vendor/bin/archer` to run the entire suite.
- Generate a coverage report with `vendor/bin/archer c path/to/tests`, or simply
`vendor/bin/archer c` to generate coverage for the entire suite. The coverage
report will be created at `artifacts/tests/coverage/index.html`.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright © 2014 Erin Millard
Copyright © 2016 Erin Millard

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
41 changes: 18 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,24 @@

*NPM integration for Composer packages.*

[![The most recent stable version is 2.1.1][version-image]][Semantic versioning]
[![Current build status image][build-image]][Current build status]
[![Current coverage status image][coverage-image]][Current coverage status]
[![Current version image][version-image]][current version]
[![Current build status image][build-image]][current build status]
[![Current coverage status image][coverage-image]][current coverage status]

[build-image]: http://img.shields.io/travis/eloquent/composer-npm-bridge/develop.svg?style=flat-square "Current build status for the develop branch"
[coverage-image]: https://img.shields.io/codecov/c/github/eloquent/composer-npm-bridge/develop.svg?style=flat-square "Current test coverage for the develop branch"
[current build status]: https://travis-ci.org/eloquent/composer-npm-bridge
[current coverage status]: https://codecov.io/github/eloquent/composer-npm-bridge
[current version]: https://packagist.org/packages/eloquent/composer-npm-bridge
[version-image]: https://img.shields.io/packagist/v/eloquent/composer-npm-bridge.svg?style=flat-square "This project uses semantic versioning"

## Installation and documentation

* Available as [Composer] package [eloquent/composer-npm-bridge].
* [API documentation] available.

## Requirements

* The `npm` executable must be available in PATH
* The `npm` executable must be available in PATH.

## Usage

Expand All @@ -26,6 +32,8 @@ NPM dependencies are specified via a [package.json] configuration file in the
root directory of the Composer package. Source control should be configured to
ignore NPM's `node_modules` directory, similar to Composer's `vendor` directory.

[package.json]: https://npmjs.org/doc/json.html

## How does it work?

The *Composer NPM bridge* is a Composer plugin that automatically installs and
Expand All @@ -44,27 +52,14 @@ NPM dependencies will be installed exactly as if `npm install` were run from the
root directory of the package. This applies even if the package is installed as
a dependency.

[install]: https://npmjs.org/doc/install.html
[npm]: https://npmjs.org/
[shrinkwrap]: https://npmjs.org/doc/shrinkwrap.html
[update]: https://npmjs.org/doc/update.html

## Caveats

Because NPM dependencies are installed underneath the root directory of the
Composer package, Composer may complain about working copy changes when the
package is installed as a dependency. Source control should be configured to
ignore the `node_modules` directory in order to avoid this.

<!-- References -->

[install]: https://npmjs.org/doc/install.html
[NPM]: https://npmjs.org/
[package.json]: https://npmjs.org/doc/json.html
[shrinkwrap]: https://npmjs.org/doc/shrinkwrap.html
[update]: https://npmjs.org/doc/update.html

[API documentation]: http://lqnt.co/composer-npm-bridge/artifacts/documentation/api/
[Composer]: http://getcomposer.org/
[build-image]: http://img.shields.io/travis/eloquent/composer-npm-bridge/develop.svg "Current build status for the develop branch"
[Current build status]: https://travis-ci.org/eloquent/composer-npm-bridge
[coverage-image]: http://img.shields.io/coveralls/eloquent/composer-npm-bridge/develop.svg "Current test coverage for the develop branch"
[Current coverage status]: https://coveralls.io/r/eloquent/composer-npm-bridge
[eloquent/composer-npm-bridge]: https://packagist.org/packages/eloquent/composer-npm-bridge
[Semantic versioning]: http://semver.org/
[version-image]: http://img.shields.io/:semver-2.1.1-brightgreen.svg "This project uses semantic versioning"
10 changes: 6 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,14 @@
"type": "composer-plugin",
"require": {
"php": ">=5.3",
"composer-plugin-api": "1.0.0",
"icecave/isolator": "~2"
"composer-plugin-api": "^1",
"icecave/isolator": "^2|^3"
},
"require-dev": {
"composer/composer": "dev-master@dev",
"icecave/archer": "~1"
"composer/composer": "dev-master",
"eloquent/phony": "^0.8",
"icecave/archer": "dev-develop",
"phpunit/phpunit": "^4"
},
"autoload": {
"psr-4": {
Expand Down
Loading

0 comments on commit c9a4c52

Please sign in to comment.