diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..6e550ac --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,4 @@ +# Release Notes for Flare + +## 4.0.0 +- Initial release diff --git a/README.md b/README.md new file mode 100644 index 0000000..5d8726c --- /dev/null +++ b/README.md @@ -0,0 +1,56 @@ +# Flare + +Flareapp.io integration for Craft CMS + +## Requirements + +This plugin requires Craft CMS 4.12.0 or later, and PHP 8.1 or later -
and an account at [flareapp.io](https://flareapp.io/?via=studioespresso) *(Affiliate link, you're supporting further maintenance of this plugin by signing up through that link - thanks!)* + +## Installation + +You can install this plugin from the Plugin Store or with Composer. + +#### From the Plugin Store + +Go to the Plugin Store in your project’s Control Panel and search for “Flare”. Then press “Install”. + +#### With Composer + +Open your terminal and run the following commands: + +```shell +cd /path/to/my-project.test +(ddev/php) composer require studioespresso/craft-flare +(ddev/php) craft plugin/install flare +``` + +## Configuration +Create a project in your Flare account, copy the API key and add it in the plugin settings. + +Alternatively, you can use the ``flare.php`` configuration file to manage this. This file is environment-aware, like any other Craft CMS configuration. You can find an example below. + +````php + [ + 'enabled' => false, + 'apiKey' => \craft\helpers\App::env('FLARE_API_KEY'), + 'excludedExceptions' => [ + ErrorException::class, + ] + ], + 'production' => [ + 'enabled' => true, + ] +]; +```` + +## Testing +Once you've added the API key for your Flare project, you can use a built-in console command to send a test exception to Flare: + +````shell +(ddev/php) craft flare/test/index +# That should result on the following message: +Exception reported to flareapp.io, check your project there to see if it shows up +```` diff --git a/composer.json b/composer.json index b4ea3fe..e3dd8b6 100644 --- a/composer.json +++ b/composer.json @@ -3,6 +3,7 @@ "description": "Flare.io integration for Craft CMS", "type": "craft-plugin", "license": "mit", + "version": "4.0.0", "support": { "email": "support@studioespresso.co", "issues": "https://github.com/studioespresso/craft-flare/issues?state=open",