Skip to content

Commit

Permalink
added utilities
Browse files Browse the repository at this point in the history
  • Loading branch information
EmanueleMinotto committed Feb 8, 2015
1 parent 9152a94 commit 0810ba2
Show file tree
Hide file tree
Showing 6 changed files with 54 additions and 3 deletions.
1 change: 1 addition & 0 deletions .coveralls.yml
@@ -0,0 +1 @@
src_dir: .
1 change: 1 addition & 0 deletions .gitignore
@@ -1,3 +1,4 @@
/build
/composer.lock
/phpunit.xml
/vendor
13 changes: 12 additions & 1 deletion .travis.yml
Expand Up @@ -6,8 +6,19 @@ php:
- 5.6
- hhvm

env:
global:
secure: tX0ZwCBxlIaKfaiIvZrNHL7jjKG3lW6J4sr38rJbb+gNmVMdxLwZKbaiXSEodSxDA94GCxcfTvhQGgfNeDvO40PyyvsVaU41u7DXmjwtUSzKSuVDg3tuYuQUDkVgomHHC55m17kdxX4fvBnnMopmAz+ewvJDEXbg10OEcsNXA+U=

before_script:
- composer install
- composer require satooshi/php-coveralls:~0.6 --dev

script:
- vendor/bin/phpunit --coverage-clover build/logs/clover.xml

after_script:
- php vendor/bin/coveralls -v
- if [ $TRAVIS_PHP_VERSION = '5.6' ]; then sh generate-api.sh; fi

notifications:
email: false
12 changes: 10 additions & 2 deletions README.md
@@ -1,8 +1,16 @@
Embedly Service Provider [![Build Status](https://travis-ci.org/EmanueleMinotto/EmbedlyServiceProvider.svg)](https://travis-ci.org/EmanueleMinotto/EmbedlyServiceProvider)
====================
Embedly Service Provider
========================

[![Build Status](https://img.shields.io/travis/EmanueleMinotto/EmbedlyServiceProvider.svg?style=flat)](https://travis-ci.org/EmanueleMinotto/EmbedlyServiceProvider)
[![SensioLabs Insight](https://img.shields.io/sensiolabs/i/95a26db2-bd04-4c3c-b3e5-37cab79fa6b7.svg?style=flat)](https://insight.sensiolabs.com/projects/95a26db2-bd04-4c3c-b3e5-37cab79fa6b7)
[![Coverage Status](https://img.shields.io/coveralls/EmanueleMinotto/EmbedlyServiceProvider.svg?style=flat)](https://coveralls.io/r/EmanueleMinotto/EmbedlyServiceProvider)
[![Scrutinizer Code Quality](https://img.shields.io/scrutinizer/g/EmanueleMinotto/EmbedlyServiceProvider.svg?style=flat)](https://scrutinizer-ci.com/g/EmanueleMinotto/EmbedlyServiceProvider/)
[![Total Downloads](https://img.shields.io/packagist/dt/emanueleminotto/embedly-service-provider.svg?style=flat)](https://packagist.org/packages/emanueleminotto/embedly-service-provider)

An [embed.ly](http://embed.ly) service provider for [Silex](http://silex.sensiolabs.org/).

API: [emanueleminotto.github.io/EmbedlyServiceProvider](http://emanueleminotto.github.io/EmbedlyServiceProvider/)

## Install
Install Silex using [Composer](http://getcomposer.org/).

Expand Down
21 changes: 21 additions & 0 deletions generate-api.sh
@@ -0,0 +1,21 @@
# Get ApiGen.phar
wget http://www.apigen.org/apigen.phar

# Generate Api
php apigen.phar generate -s . --exclude=vendor --exclude=Tests -d ../gh-pages --todo --tree --no-source-code
cd ../gh-pages

# Set identity
git config --global user.email "travis@travis-ci.org"
git config --global user.name "Travis"

# Add branch
git init
git remote add origin https://${GH_TOKEN}@github.com/EmanueleMinotto/EmbedlyServiceProvider.git > /dev/null
git checkout -B gh-pages
git rm -rf .

# Push generated files
git add --all .
git commit -m "API updated"
git push origin gh-pages -fq > /dev/null
9 changes: 9 additions & 0 deletions phpunit.xml.dist
Expand Up @@ -9,4 +9,13 @@
<env name="api_key" value=""/>
<env name="url" value="http://embed.ly/"/>
</php>
<filter>
<whitelist>
<directory>./</directory>
<exclude>
<directory>./Tests</directory>
<directory>./vendor</directory>
</exclude>
</whitelist>
</filter>
</phpunit>

0 comments on commit 0810ba2

Please sign in to comment.