Skip to content

Commit

Permalink
- Updates readme
Browse files Browse the repository at this point in the history
- rerenames service provider
  • Loading branch information
schuppo committed Feb 12, 2015
1 parent 0df5520 commit fdd8c5b
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 44 deletions.
97 changes: 54 additions & 43 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ PasswordStrength Package [![Build Status](https://travis-ci.org/schuppo/Password

This package provides a validator that ensures strong passwords in Laravel 4 applications. It is influenced a lot by [PasswordStrengthBundle for Symfony 2](https://github.com/jbafford/PasswordStrengthBundle).

It is in a early stage of development but should fulfill its purpose.
It is out now for a while and since there were no complaints it very likely fulfills its purpose.

The provided validations include:

Expand All @@ -12,68 +12,42 @@ The provided validations include:
- check if input contains mixed case characters
- check if input contains symbols

#History
**[1.0.1]
Starts to make package laravel 5 ready

**[0.7]**
Fixes typo in readme

**[0.6]**

- New validation rule to check if input contains symbols. Thanks to [closca](https://github.com/closca) for providing this new feature.

**[0.5.3]**

- Added new version to composer.json

**[0.5.2]**

- Small changes in README.md

**[0.5.1]**

- Minimum requirement (PHP 5.4 because of array chains) is now recognized by composer.json

**[0.4.1]**

- The package works properly now when other extensions of laravel's validator are used as well (like [unique-with](https://github.com/felixkiss/uniquewith-validator)).
- The package is able to take localization overwrites now as described in the [laravel docs](http://laravel.com/docs/localization#overriding-package-language-files)

**[0.3.1]**

- Fixed: Package validator doesn't overwrite custom validation errror messages any more. Not functional tested though because I have no clue how to set up a test which controls the passing of variables from the password strength package to the native validator INSIDE the package's test folders. Any suggestions?

#Documentation

##Installation

### Get the package
** For Laravel 4 users **

Add the following in your `composer.json`:
Add the following to your `composer.json`:

```json
{
"require": {
"schuppo/password-strength": "~0.*"
"schuppo/password-strength": "~0.7"
}
}
```
and afterwards ```composer update```.

Or just ```composer require schuppo/password-strength:"~0.7@dev"```.

You have to set in ```composer.json```
** For Laravel 5 users **

```json
"minimum-stability": "dev"
{
"require": {
"schuppo/password-strength": "~1.0"
}
}
```
and afterwards ```composer update```.

to make it work.

Because it is in such an early stage it is not a good idea to use it in production environments. Seriously. (By the way, this is my first contribution on GitHub and to Laravel so don't be too harsh.)
If you trust me that the code is unit tested you don't have to download the package's dev dependencies. Updating the application with `composer udate --no-dev` is best choice then.
Or just ```composer require schuppo/password-strength:"~1.0@dev"```.

### Initialize the package

To start using the package, you have to add it to the arraykey `providers` in `app/config/app.php`:
To start using the package, you have to add it to the array key `providers` in `app/config/app.php`:

```php
// app/config/app.php
Expand All @@ -88,7 +62,7 @@ return array(
```

##Usage
Now Laravel's native `Validator` class is extended with four rules:
Now Laravel's native `Validator` is extended by four rules:

- case_diff
- numbers
Expand All @@ -108,6 +82,43 @@ $v->passes(); // returns true;

Notice that you can validate any value with the new rules. The only reason why this package is called "Password Strength Package" is that it describes its foremost purpose.

#History
**[1.0.2]**
Updates README.md

**[1.0.1]**
Starts to make package laravel 5 ready

**[0.7]**
Fixes typo in readme

**[0.6]**

- New validation rule to check if input contains symbols. Thanks to [closca](https://github.com/closca) for providing this new feature.

**[0.5.3]**

- Added new version to composer.json

**[0.5.2]**

- Small changes in README.md

**[0.5.1]**

- Minimum requirement (PHP 5.4 because of array chains) is now recognized by composer.json

**[0.4.1]**

- The package works properly now when other extensions of laravel's validator are used as well (like [unique-with](https://github.com/felixkiss/uniquewith-validator)).
- The package is able to take localization overwrites now as described in the [laravel docs](http://laravel.com/docs/localization#overriding-package-language-files)

**[0.3.1]**

- Fixed: Package validator doesn't overwrite custom validation errror messages any more. Not functional tested though because I have no clue how to set up a test which controls the passing of variables from the password strength package to the native validator INSIDE the package's test folders. Any suggestions?





#License
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
use Illuminate\Support\ServiceProvider as IlluminateServiceProvider;
use Illuminate\Translation\Translator;

class ServiceProvider extends IlluminateServiceProvider {
class PasswordStrengthServiceProvider extends IlluminateServiceProvider {

/**
* Indicates if loading of the provider is deferred.
Expand Down

0 comments on commit fdd8c5b

Please sign in to comment.