Remove spaces from README code samples.

This commit is contained in:
Rajib Ahmed 2013-07-18 11:51:02 +02:00
parent 2d4458fbed
commit 14989b0e9e

View File

@ -52,13 +52,12 @@ If you're not familiar with Composer, please see <http://getcomposer.org/>.
1. Add php-resque to your application's composer.json.
```json
{
...
//...
"require": {
"chrisboulton/php-resque": "1.2.x"
},
...
// ...
}
```
@ -78,7 +77,6 @@ If you're not familiar with Composer, please see <http://getcomposer.org/>.
Jobs are queued as follows:
```php
// Required if redis is located elsewhere
Resque::setBackend('localhost:6379');
@ -86,7 +84,6 @@ Jobs are queued as follows:
'name' => 'Chris'
);
Resque::enqueue('default', 'My_Job', $args);
```
### Defining Jobs ###
@ -94,7 +91,6 @@ Jobs are queued as follows:
Each job should be in it's own class, and include a `perform` method.
```php
class My_Job
{
public function perform()
@ -103,7 +99,6 @@ Each job should be in it's own class, and include a `perform` method.
echo $this->args['name'];
}
}
```
When the job is run, the class will be instantiated and any arguments
@ -120,7 +115,6 @@ The `tearDown` method if defined, will be called after the job finishes.
```php
class My_Job
{
public function setUp()
@ -191,9 +185,9 @@ not having a single environment such as with Ruby, the PHP port makes
*no* assumptions about your setup.
To start a worker, it's very similar to the Ruby version:
```sh
$ QUEUE=file_serve php bin/resque
```
It's your responsibility to tell the worker which file to include to get
your application underway. You do so by setting the `APP_INCLUDE` environment
variable: