Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 19 additions & 4 deletions docs/src/usage/php.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,35 @@ All classes live under the `Biscuit\Auth` namespace.

## Install

Prebuilt binaries are available on the [GitHub releases page](https://github.com/ptondereau/biscuit-php/releases).
You can also compile the extension from source — see the
[project README](https://github.com/ptondereau/biscuit-php#installation) for build instructions.
The recommended way to install the extension is via [PIE](https://github.com/php/pie)
(the PHP Installer for Extensions), which handles building and installing the extension for you:

```sh
pie install ptondereau/biscuit-php
```

Prebuilt binaries are also available on the [GitHub releases page](https://github.com/ptondereau/biscuit-php/releases),
and you can compile the extension from source. See the
[project README](https://github.com/ptondereau/biscuit-php#installation) for details.

In `composer.json`:

```json
{
"require": {
"ext-biscuit-php": "*"
"ext-biscuit_php": "*"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the mixed kebab/snake case is surprising. is this required by pie?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes this because the old CLI pecl support only underscore as a separator, so pie decided to have the same behavior

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

}
}
```

### Symfony

Symfony users can integrate Biscuit through the dedicated bundle:
[ptondereau/biscuit-sf-bundle](https://github.com/ptondereau/biscuit-sf-bundle).
It wires the extension into the Symfony container and provides ready-to-use services.
Comment thread
ptondereau marked this conversation as resolved.

> **Warning:** The Symfony bundle is not stable yet. Expect breaking changes before the first stable release.

## Create a root key

```php
Expand Down
Loading