# Favicon by RFG - WordPress plugin

## Create a new version

WordPress login is phbernard. To get the password, visit chrome://settings/passwords and display the password for login.wordpress.org / phbernard.

If svn is not happy about credentials, use it with:

```bash
svn commit --username phbernard --password [PASS] ...
```

### Create the dedicated branch

```
NEW_VERSION=1.2.3
svn copy http://phbernard@plugins.svn.wordpress.org/favicon-by-realfavicongenerator/trunk \
         http://phbernard@plugins.svn.wordpress.org/favicon-by-realfavicongenerator/branches/$NEW_VERSION \
         -m "Version $NEW_VERSION"
svn update
```

### Update the plugin version

Update the version in `branches/$NEW_VERSION/README.txt` and `branches/$NEW_VERSION/favicon-by-realfavicongenerator.php`

Add a new entry in the change log of `branches/$NEW_VERSION/README.txt`.

### Update

Do your magic

### Release the new version

```
cd trunk
svn merge --reintegrate http://phbernard@plugins.svn.wordpress.org/favicon-by-realfavicongenerator/branches/$NEW_VERSION
# Make sure everything is correct
svn commit -m "Release $NEW_VERSION"
svn copy http://phbernard@plugins.svn.wordpress.org/favicon-by-realfavicongenerator/trunk \
      http://phbernard@plugins.svn.wordpress.org/favicon-by-realfavicongenerator/tags/$NEW_VERSION -m "Tag $NEW_VERSION"
```

## Clean code

Install [PHP Code Sniffer](https://github.com/squizlabs/PHP_CodeSniffer) and [PHP CS WordPress Standard](https://github.com/WordPress/WordPress-Coding-Standards)

```
cd branches/1.2.3
phpcs --standard=WordPress .
```

To fix everything automatically:

```
phpcbf --standard=WordPress .
```
