-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit c4f48a2
Showing
24 changed files
with
1,099 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# General backup/log/swap files | ||
*~ | ||
*.DS_Store | ||
*.log | ||
*.out | ||
*.so | ||
*.swp | ||
|
||
# Custom files | ||
*.map | ||
*.sass-cache* | ||
|
||
# Composer | ||
vendor | ||
composer.lock | ||
|
||
# Node | ||
node_modules | ||
|
||
# PhpStorm | ||
.idea | ||
|
||
# PHPUnit | ||
phpunit.xml | ||
|
||
# This should stay at the bottom | ||
!.gitkeep |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"preset": "wordpress", | ||
"fileExtensions": [ ".js" ], | ||
"excludeFiles": [ "**/*.min.js" ] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"curly": true, | ||
"eqeqeq": true, | ||
"es3": true, | ||
"forin": true, | ||
"freeze": true, | ||
"futurehostile": true, | ||
"globals": { | ||
"_": false, | ||
"Backbone": false, | ||
"jQuery": false, | ||
"JSON": false, | ||
"wp": false | ||
}, | ||
"latedef": true, | ||
"noarg": true, | ||
"nonbsp": true, | ||
"nonew": true, | ||
"singleGroups": true, | ||
"strict": true, | ||
"undef": true, | ||
"unused": true, | ||
|
||
"browser": true, | ||
"qunit": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
language: php | ||
|
||
php: | ||
- 5.4 | ||
- 5.5 | ||
- 5.6 | ||
- 7.0 | ||
- hhvm | ||
- nightly | ||
|
||
sudo: false | ||
|
||
matrix: | ||
fast_finish: true | ||
allow_failures: | ||
- php: hhvm | ||
- php: nightly | ||
|
||
before_install: | ||
- travis_retry composer self-update | ||
|
||
install: | ||
- travis_retry composer install --no-interaction --prefer-source | ||
|
||
before_script: | ||
- if [[ $TRAVIS_PHP_VERSION != 'hhvm' ]]; then phpenv config-rm xdebug.ini; fi | ||
|
||
script: | ||
- find src \( -name '*.php' \) -exec php -l {} \; | ||
- phpunit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# Changelog | ||
|
||
## 1.0.0 | ||
* Initial release. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
Thanks for contributing—you rock! | ||
|
||
# Getting Started | ||
* Make sure you have a [GitHub account](https://github.com/signup/free). | ||
* See if your issue has been discussed (or even fixed) earlier. You can [search for existing issues](https://github.com/tfrommen/adorable-avatars/issues?q=is%3Aissue). | ||
* Assuming it does not already exist, [create a new issue](https://github.com/tfrommen/adorable-avatars/issues/new). | ||
* Clearly describe the issue including steps to reproduce when it is a bug. | ||
* Make sure you fill in the earliest version that you know has the issue. | ||
* Fork the repository on GitHub. | ||
|
||
# Making Changes | ||
* Create a topic branch from where you want to base your work. | ||
* This is usually the `master` branch. | ||
* Only target other branches if you are certain your fix must be on that branch. | ||
* To quickly create a topic branch based on the `master` branch: | ||
* `git checkout -b issue/%YOUR-ISSUE-NUMBER%_%DESCRIPTIVE-TITLE% master` | ||
* A good example is `issue/123_settings_page_typo`. | ||
* Make commits of logical units. | ||
* Make sure your commit messages are helpful. | ||
|
||
# Submitting Changes | ||
* Push your changes to the according topic branch in your fork of the repository. | ||
* [Create a pull request](https://github.com/tfrommen/adorable-avatars/compare) to the original repository. | ||
* Wait for feedback. | ||
|
||
# License | ||
By contributing code to this plugin, you grant its use under the [GNU General Public License v3](http://www.gnu.org/licenses/gpl-3.0.html). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,190 @@ | ||
/* jshint node:true */ | ||
module.exports = function( grunt ) { | ||
'use strict'; | ||
|
||
var configObject = { | ||
config: { | ||
assets: { | ||
src: 'resources/assets/', | ||
dest: 'assets/' | ||
}, | ||
src: 'src/', | ||
tests: { | ||
phpunit: 'tests/phpunit/' | ||
} | ||
}, | ||
|
||
imagemin: { | ||
options: { | ||
optimizationLevel: 7 | ||
}, | ||
assets: { | ||
expand: true, | ||
cwd: '<%= config.assets.src %>', | ||
src: [ '*.{gif,jpeg,jpg,png}' ], | ||
dest: '<%= config.assets.dest %>' | ||
} | ||
}, | ||
|
||
jscs: { | ||
options: { | ||
config: true | ||
}, | ||
grunt: { | ||
src: [ 'Gruntfile.js' ] | ||
} | ||
}, | ||
|
||
jshint: { | ||
options: { | ||
jshintrc: true, | ||
reporter: require( 'jshint-stylish' ) | ||
}, | ||
grunt: { | ||
src: [ 'Gruntfile.js' ] | ||
} | ||
}, | ||
|
||
jsonlint: { | ||
configs: { | ||
src: [ '.{jscs,jshint}rc' ] | ||
}, | ||
json: { | ||
src: [ '*.json' ] | ||
} | ||
}, | ||
|
||
jsvalidate: { | ||
options: { | ||
globals: {}, | ||
esprimaOptions: {}, | ||
verbose: false | ||
}, | ||
grunt: { | ||
src: [ 'Gruntfile.js' ] | ||
} | ||
}, | ||
|
||
lineending: { | ||
options: { | ||
eol: 'lf', | ||
overwrite: true | ||
}, | ||
grunt: { | ||
src: [ 'Gruntfile.js' ] | ||
} | ||
}, | ||
|
||
phplint: { | ||
src: { | ||
src: [ '<%= config.src %>**/*.php' ] | ||
}, | ||
tests: { | ||
src: [ '<%= config.tests.phpunit %>**/*.php' ] | ||
} | ||
}, | ||
|
||
watch: { | ||
options: { | ||
dot: true, | ||
spawn: true, | ||
interval: 2000 | ||
}, | ||
|
||
assets: { | ||
files: [ '<%= config.assets.src %>*.{gif,jpeg,jpg,png}' ], | ||
tasks: [ | ||
'imagemin:assets' | ||
] | ||
}, | ||
|
||
configs: { | ||
files: [ '.{jscs,jshint}rc' ], | ||
tasks: [ | ||
'newer:jsonlint:configs' | ||
] | ||
}, | ||
|
||
grunt: { | ||
files: [ 'Gruntfile.js' ], | ||
tasks: [ | ||
'newer:jscs:grunt', | ||
'newer:jshint:grunt', | ||
'newer:lineending:grunt', | ||
'newer:jsvalidate:grunt' | ||
] | ||
}, | ||
|
||
json: { | ||
files: [ '*.json' ], | ||
tasks: [ | ||
'newer:jsonlint:json' | ||
] | ||
}, | ||
|
||
php: { | ||
files: [ | ||
'<%= config.src %>**/*.php', | ||
'<%= config.tests.phpunit %>**/*.php' | ||
], | ||
tasks: [ | ||
'newer:phplint', | ||
'phpunit' | ||
] | ||
}, | ||
|
||
travis: { | ||
files: [ '.travis.yml' ], | ||
tasks: [ | ||
'travis-lint' | ||
] | ||
} | ||
} | ||
}; | ||
|
||
require( 'load-grunt-tasks' )( grunt ); | ||
|
||
grunt.initConfig( configObject ); | ||
|
||
// PHPUnit task. | ||
grunt.registerTask( 'phpunit', function() { | ||
grunt.util.spawn( { | ||
cmd: 'phpunit', | ||
opts: { | ||
stdio: 'inherit' | ||
} | ||
}, this.async() ); | ||
} ); | ||
|
||
grunt.registerTask( 'assets', configObject.watch.assets.tasks ); | ||
|
||
grunt.registerTask( 'configs', configObject.watch.configs.tasks ); | ||
|
||
grunt.registerTask( 'grunt', configObject.watch.grunt.tasks ); | ||
|
||
grunt.registerTask( 'json', configObject.watch.json.tasks ); | ||
|
||
grunt.registerTask( 'php', configObject.watch.php.tasks ); | ||
|
||
grunt.registerTask( 'travis', configObject.watch.travis.tasks ); | ||
|
||
grunt.registerTask( 'common', [ | ||
'configs', | ||
'grunt', | ||
'json', | ||
'php', | ||
'travis' | ||
] ); | ||
|
||
grunt.registerTask( 'develop', [ | ||
'common' | ||
] ); | ||
|
||
grunt.registerTask( 'pre-commit', [ | ||
'newer-clean', | ||
'common', | ||
'assets' | ||
] ); | ||
|
||
grunt.registerTask( 'default', 'develop' ); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
The MIT License (MIT) | ||
|
||
Copyright (c) 2016 Thorsten Frommen | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Adorable Avatars | ||
|
||
[![Latest Stable Version](https://poser.pugx.org/tfrommen/adorable-avatars/v/stable)](https://packagist.org/packages/tfrommen/adorable-avatars) | ||
[![Project Status](http://opensource.box.com/badges/active.svg)](http://opensource.box.com/badges) | ||
[![Build Status](https://travis-ci.org/tfrommen/adorable-avatars.svg?branch=master)](http://travis-ci.org/tfrommen/adorable-avatars) | ||
[![License](https://poser.pugx.org/tfrommen/adorable-avatars/license)](https://packagist.org/packages/tfrommen/adorable-avatars) | ||
|
||
This plugin integrates the [Adorable Avatars](http://avatars.adorable.io/) avatar placeholder service into WordPress. | ||
|
||
## Installation | ||
|
||
1. [Download ZIP](https://github.com/tfrommen/adorable-avatars/archive/master.zip). | ||
1. Upload contents to the `/wp-content/plugins` directory on your web server. | ||
1. Activate the plugin through the _Plugins_ menu in WordPress. | ||
1. Select _Adorable Avatars_ as default avatar setting on the _Discussion Settings_ page in your WordPress backend. | ||
|
||
## Screenshots | ||
|
||
![Setting](resources/assets/screenshot-1.png) | ||
**Default Avatar setting** - Here you can select _Adorable Avatars_ as default avatar setting. | ||
|
||
## Contribution | ||
|
||
If you have a feature request, or if you have developed the feature already, please feel free to use the Issues and/or Pull Requests section. | ||
|
||
Of course, you can also provide me with translations if you would like to use the plugin in another not yet included language. | ||
|
||
## Changelog | ||
|
||
[Changelog](CHANGELOG.md) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php # -*- coding: utf-8 -*- | ||
/** | ||
* Plugin Name: Adorable Avatars | ||
* Plugin URI: https://github.com/tfrommen/adorable-avatars | ||
* Description: This plugin integrates the Adorable Avatars avatar placeholder service into WordPress. | ||
* Author: Thorsten Frommen | ||
* Author URI: http://tfrommen.de | ||
* Version: 1.0.0 | ||
* Text Domain: adorable-avatars | ||
* License: MIT | ||
*/ | ||
|
||
defined( 'ABSPATH' ) or die(); | ||
|
||
require_once __DIR__ . '/src/' . basename( __FILE__ ); |
Oops, something went wrong.