You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add composer install directory to $PATH `~/.composer/vendor/bin/`
26
26
27
-
#### Install PHPUnit for Testing
28
-
```
29
-
composer global require "phpunit/phpunit=4.8.*"
27
+
### phpenv
28
+
29
+
[phpenv](https://github.com/phpenv/phpenv-installer) is useful for testing locally across different PHP versions.
30
+
31
+
### Developing your app against a local version of the SparkPost library
32
+
33
+
If you're working on the library and your app together, you can tell Composer to get `php-sparkpost` from a local path. With a directory structure such as:
34
+
35
+
home
36
+
- php-sparkpost
37
+
- my-app
38
+
- composer.json
39
+
- .. etc
40
+
41
+
Use the following for `my-app/composer.json`:
42
+
```json
43
+
{
44
+
"name": "sparkpost/php_simple_email_send",
45
+
"description": "a small test program to send an email",
46
+
"repositories": [
47
+
{
48
+
"type": "path",
49
+
"url": "../php-sparkpost"
50
+
}
51
+
],
52
+
"require": {
53
+
"php-http/guzzle6-adapter": "^1.1",
54
+
"guzzlehttp/guzzle": "^6.0",
55
+
"sparkpost/sparkpost": "dev-master"
56
+
}
57
+
}
30
58
```
31
59
60
+
61
+
### Memory
32
62
We recommend increasing PHP’s memory limit, by default it uses 128MB. We ran into some issues during local development without doing so. You can do this by editing your php.ini file and modifying `memory_limit`. We set ours to `memory_limit = 1024M`.
33
63
34
64
#### Install XDebug for code coverage generation
@@ -68,6 +98,7 @@ Once you are setup for local development:
68
98
69
99
## Releasing
70
100
71
-
* Update version information in composer.json during development.
72
-
* Once its been merged down, create a release tag in git.
101
+
* Update version in the [library](https://github.com/SparkPost/php-sparkpost/blob/eeb6ba971584fcc4c12fd69247c6b24df7827af5/lib/SparkPost/SparkPost.php#L16) during development. This is used in the `user_agent` of your requests.
102
+
103
+
* Once it's been merged down, create a release tag in git.
73
104
* Composer will automatically pickup the new tag and present it as a release.
0 commit comments