From: Hypolite Petovan Date: Sun, 25 Nov 2018 07:16:41 +0000 (-0500) Subject: [twitter] Update config file style/name X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=b655c18adb095c0f06af539bf8fd2f7f9917e070;p=friendica-addons.git [twitter] Update config file style/name --- diff --git a/twitter/README.md b/twitter/README.md index 357180cc..f1f87541 100644 --- a/twitter/README.md +++ b/twitter/README.md @@ -16,13 +16,21 @@ After the registration please enter the values for "Consumer Key" and "Consumer ## Alternative configuration -Add your key pair to your global config/addon.ini.php. +Open the `config/local.config.php` file and add "twitter" to the list of activated addons: - [twitter] - consumerkey = your consumer_key here - consumersecret = your consumer_secret here + 'system' => [ + ... + 'addon' => '...,twitter' + ... + ] + +Add your key pair to your global `config/addon.config.php`. + + 'twitter' => [ + 'consumerkey' => 'your consumer_key here', + 'consumersecret' => 'your consumer_secret here', + ], -To activate the addon itself add it to the [system] addon setting. After this, users can configure their Twitter account settings from "Settings -> Addon Settings". ## License diff --git a/twitter/config/twitter.config.php b/twitter/config/twitter.config.php new file mode 100644 index 00000000..e39de2f9 --- /dev/null +++ b/twitter/config/twitter.config.php @@ -0,0 +1,16 @@ + [ + // consumerkey (String) + // OAuth Consumer Key provided by Twitter on registering an app at https://twitter.com/apps + 'consumerkey' => '', + + // consumersecret (String) + // OAuth Consumer Secret provided by Twitter on registering an app at https://twitter.com/apps + 'consumersecret' => '', + ], +]; diff --git a/twitter/config/twitter.ini.php b/twitter/config/twitter.ini.php deleted file mode 100644 index 5359fd6d..00000000 --- a/twitter/config/twitter.ini.php +++ /dev/null @@ -1,16 +0,0 @@ - [ + * 'consumerkey' => '', + * 'consumersecret' => '', + * ], * - * To activate the addon itself add it to the [system] addon + * To activate the addon itself add it to the system.addon * setting. After this, your user can configure their Twitter account settings * from "Settings -> Addon Settings". * @@ -141,7 +142,7 @@ function twitter_uninstall() function twitter_load_config(App $a) { - $a->loadConfigFile(__DIR__ . '/config/twitter.ini.php'); + $a->loadConfigFile(__DIR__ . '/config/twitter.config.php'); } function twitter_check_item_notification(App $a, array &$notification_data)