Skip to content

Commit 96824e8

Browse files
committed
Merge branch 'devel' of https://github.com/arangodb/arangodb-php into devel
2 parents 7b8ec50 + f7b36f2 commit 96824e8

File tree

2 files changed

+16
-84
lines changed

2 files changed

+16
-84
lines changed

CONTRIBUTING.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,21 +17,24 @@ Please also take the time to check there are no similar/identical issues open ye
1717

1818
## Contributing features, documentation, tests
1919

20+
__Important: You must use the Apache License for your changes and have signed our [CLA](https://www.arangodb.com/documents/cla.pdf). We cannot accept pull requests from contributors that did not sign the CLA.__
21+
2022
* Create a new branch in your fork, based on the devel branch
2123
* Develop and test your modifications there
2224
* Commit as you like, but preferably in logical chunks. Use meaningful commit messages and make sure you do not commit unnecessary files. It is normally a good idea to reference the issue number from the commit message so the issues will get updated automatically with comments
2325
* Make sure the ArangoDB version is the correct one to use with your client version. The client version follows the ArangoDB version. [More info on this, here.](https://github.com/arangodb/ArangoDB-PHP/wiki/Important-versioning-information-on-ArangoDB-PHP)
2426
* Make sure the unmodified clone works locally before making any code changes. You can do so by running the included test suite (phpunit --testsuite ArangoDB-PHP)
25-
* If the modifications change any documented behavior or add new features, document the changes. The documentation can be found in the docs directory. To recreate the documentation locally, follow the steps in the next paragraph "Generating Documentation". This will re-create all documentation files in the docs directory in your repository. You can inspect the documentation in this folder using a browser. We recently agreed that future documentation should be written in American English (AE).
27+
* If the modifications change any documented behavior or add new features, __please document the changes in the PHPDOC section__ of the method(s) and/or class(es). We recently agreed that future documentation should be written in American English (AE).
28+
* If a feature was added, please also write accompanying tests.
2629
* When done, run the complete test suite and make sure all tests pass
27-
* When finished, push the changes to your GitHub repository and send a pull request from your fork to the ArangoDB-PHP repository. Please make sure to select the appropriate branches there. This will most likely be **devel**.
28-
* You must use the Apache License for your changes and have signed our [CLA](https://www.arangodb.com/documents/cla.pdf). We cannot accept pull requests from contributors that did not sign the CLA.
29-
* Please let us know if you plan to work an a ticket. This way we can make sure we avoid redundant work
30-
30+
* When finished, push the changes to your GitHub repository and send a pull request from your fork to the ArangoDB-PHP repository's **devel** branch.
31+
* Please let us know if you plan to work on an issue. This way we can make sure we avoid redundant work
3132
* For feature requests: please clearly describe the proposed feature, additional configuration options, and side effects
3233

3334

35+
3436
## Generating documentation
37+
(This should only be done prior to tagged releases, by release managers, in order to not excessively recreate all documentation files for small changes in the devel branch)
3538

3639
Documentation is generated with the apigen generator with the following parameters (beside the source and destination definition):
3740

README.md

Lines changed: 8 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
- [Description](#description)
1919
- [Requirements](#requirements)
2020
- [Installing the PHP client](#installing)
21-
- [Using packagist/composer](#using_packagist)
21+
- [Using Composer](#using_composer)
2222
- [Cloning the git repository](#cloning_git)
2323
- [How to use the PHP client](#howto_use)
2424
- [Setting up the connection options](#setting_up_connection_options)
@@ -78,85 +78,14 @@ To get started you need PHP 5.5 or higher plus an ArangoDB server running on any
7878

7979
There are two alternative ways to get the ArangoDB PHP client:
8080

81-
* Using packagist/composer
81+
* Using Composer
8282
* Cloning the git repository
8383

84-
<a name="using_packagist"></a>
85-
## Alternative 1: Using packagist/composer
84+
<a name="using_composer"></a>
85+
## Alternative 1: Using Composer
8686

87-
When using [packagist](http://packagist.org/), the procedure is as follows:
88-
89-
Get the composer.phar file from [getcomposer.org](http://getcomposer.org):
90-
91-
curl -s http://getcomposer.org/installer | php
92-
93-
This will put the composer.phar file into the current directory. Next, create a new directory for your project, e.g. arangophp, and move into it:
94-
95-
mkdir arangophp && cd arangophp
96-
97-
Then, use composer's init command to define the initial dependencies for your project:
98-
99-
php ../composer.phar init
100-
101-
This will fire up composer's interactive config generator. It will ask you several questions, and the below example shows how you can answer them. Most questions have reasonable default settings and you can should use the defaults whenever you're unsure.
102-
When asked for a package name, type ## triagens/Arango. This is the package name for the ArangoDB PHP client. When being asked for a package number (package ##), you can either use dev-master (latest version) or one of the designated tagged versions.
103-
104-
Welcome to the Composer config generator
105-
106-
This command will guide you through creating your composer.json config.
107-
108-
Package name (/) [jsteemann/arangophp]:
109-
Description []: An example application using ArangoDB PHP client
110-
Author [jsteemann]:
111-
112-
Define your dependencies.
113-
114-
Would you like to define your dependencies interactively [yes]? yes
115-
Search for a package []: triagens/Arango
116-
117-
Found 3 packages matching triagens/Arango
118-
119-
[0] triagens/ArangoDb dev-master
120-
[1] triagens/ArangoDb V0.1.1
121-
[2] triagens/ArangoDb V0.0.1
122-
123-
Enter package ## to add, or a couple if it is not listed []: 0
124-
Search for a package []:
125-
126-
{
127-
"name": "jsteemann/arangophp",
128-
"description": "An example application using ArangoDB PHP client",
129-
"require": {
130-
"triagens/arangodb": "dev-master"
131-
},
132-
"authors": [
133-
{
134-
"name": "jsteemann",
135-
"email": "j.steemann@triagens.de"
136-
}
137-
]
138-
}
139-
140-
Do you confirm generation [yes]? yes
141-
Would you like the vendor directory added to your .gitignore [yes]?
142-
143-
The above has created a file composer.json in your current directory, which contains information about your project plus the project dependencies. The ArangoDB PHP client is the only dependency for now, and it can be installed by running the following command:
144-
145-
php ../composer.phar update
146-
Updating dependencies
147-
- Package triagens/arangodb (dev-master)
148-
Cloning e4e9107aec3d1e0c914e40436f77fed0e5df2485
149-
150-
Writing lock file
151-
Generating autoload files
152-
153-
154-
Running this command has created a subdirectory vendor in the current directory. The vendor directory contains a subdirectory triagens that contains the ArangoDB PHP client library files. The vendor directory also contains a subdirectory .composer that contains auto-generated autoloader files for all dependencies you defined in your composer.json file (the file auto-generated by running the previous init command).
155-
156-
You need to include the generated autoloader file in your project when using the ArangoDB PHP classes. You can do so by adding the following line to any PHP file that will use them:
157-
158-
```php
159-
require 'vendor/.composer/autoload.php';
87+
```
88+
composer require triagens/Arango
16089
```
16190

16291
<a name="cloning_git"></a>
@@ -198,7 +127,7 @@ require 'arangodb-php/lib/ArangoDBClient/autoloader.php';
198127
In order to use ArangoDB, you need to specify the connection options. We do so by creating a PHP array $connectionOptions. Put this code into a file named test.php in your current directory:
199128

200129
```php
201-
// use the following line when using packagist/composer
130+
// use the following line when using Composer
202131
// require __DIR__ . '/vendor/composer/autoload.php';
203132

204133
// use the following line when using git
@@ -707,7 +636,7 @@ ArangoException::disableLogging();
707636
Here's the full code that combines all the pieces outlined above:
708637

709638
```php
710-
// use the following line when using packagist/composer
639+
// use the following line when using Composer
711640
// require __DIR__ . '/vendor/composer/autoload.php';
712641

713642
// use the following line when using git

0 commit comments

Comments
 (0)