diff --git a/QvitterPlugin.php b/QvitterPlugin.php index 52353dd..a9bc3e3 100644 --- a/QvitterPlugin.php +++ b/QvitterPlugin.php @@ -45,6 +45,10 @@ class QvitterPlugin extends Plugin { · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · */ + // THESE SETTINGS CAN BE OVERRIDDEN IN CONFIG.PHP + // e.g. $config['site']['qvitter']['enabledbydefault'] = 'false'; + + // ENABLED BY DEFAULT (true/false) $settings['enabledbydefault'] = true; @@ -59,7 +63,7 @@ class QvitterPlugin extends Plugin { // URL SHORTENER $settings['urlshortenerapiurl'] = 'http://qttr.at/yourls-api.php'; - $settings['urlshortenersignature'] = 'b6afeec983'; + $settings['urlshortenersignature'] = 'b6afeec983'; /* · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · @@ -69,7 +73,12 @@ class QvitterPlugin extends Plugin { · \____) (____/ · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · */ - + + // config.php settings override the settings in this file + $configphpsettings = common_config('site','qvitter'); + foreach($configphpsettings as $configphpsetting=>$value) { + $settings[$configphpsetting] = $value; + } return $settings[$setting]; } @@ -251,7 +260,7 @@ class QvitterPlugin extends Plugin { var qvitterEnabled = '.$qvitter_enabled.'; var qvitterAllLink = \''.common_local_url('all', array('nickname' => $user->nickname)).'\'; '); - $action->script($this->path('js/toggleqvitter.js')); + $action->script($this->path('js/toggleqvitter.js?changed='.date('YmdHis',filemtime(INSTALLDIR.'/plugins/Qvitter/js/toggleqvitter.js')))); } } @@ -364,7 +373,8 @@ class QvitterPlugin extends Plugin { #site_nav_global_primary a:hover, .threaded-replies .notice-faves:before, .threaded-replies .notice-repeats:before, - .notice-reply-comments > a:before { + .notice-reply-comments > a:before, + #content .notices > .notice > .entry-metadata .conversation { color:#".$linkcolor."; } #site_nav_global_primary a:hover { diff --git a/README.md b/README.md index caee2d8..a7feb58 100644 --- a/README.md +++ b/README.md @@ -38,6 +38,21 @@ be opt-in instead. 6. Users can go to ://{instance}/settings/qvitter and enable or disable Qvitter. +Optional +----- + +For easy updates, you can use /config.php to override the settings in /plugins/Qvitter/QvitterPlugin.php. +For example, add this to your /config.php file: + +```// Qvitter-settings +$config['site']['qvitter']['enabledbydefault'] = true; +$config['site']['qvitter']['defaultbackgroundcolor'] = '#f4f4f4'; +$config['site']['qvitter']['defaultlinkcolor'] = '#0084B4'; +$config['site']['qvitter']['timebetweenpolling'] = 5000; +$config['site']['qvitter']['urlshortenerapiurl'] = 'http://qttr.at/yourls-api.php'; +$config['site']['qvitter']['urlshortenersignature'] = 'b6afeec983'; +``` + Note: Qvitter is tested with GNU Social version 1.1.1-alpha2 (7e47026085fa4f2071e694d9c3e3fe2aa5142135). @@ -58,18 +73,18 @@ TODO 1. Join _new_ external groups and follow _new_ external users ("New" meaning users/groups that the server don't know yet) -2. Creating groups, make admin, block user +1. Creating groups, make admin, block user -10. Search users +1. Search users -11. Recommended users +1. Recommended users -12. Filters (hide queets containing strings, e.g. mute users) +1. Filters (hide queets containing strings, e.g. mute users) -14. More languages, maybe make proper po/mo-files +1. More languages, maybe make proper po/mo-files -16. Admin-interface +1. Admin-interface -17. New "expand queet" api for getting conversation, retweets, favs and attachment in the same request +1. New "expand queet" api for getting conversation, retweets, favs and attachment in the same request -19. Node.js long polling server and an new api that serve aggregate of all polling users requests in one go \ No newline at end of file +1. Node.js long polling server and an new api that serve aggregate of all polling users requests in one go \ No newline at end of file diff --git a/actions/qvitter.php b/actions/qvitter.php index 9f5224f..fc69431 100644 --- a/actions/qvitter.php +++ b/actions/qvitter.php @@ -102,7 +102,7 @@ class QvitterAction extends ApiAction
In the latest versions of GNU Social, repeats/requeets do not get sent to your followers on other instances. This was possible in StatusNet, but this feature has been removed due to a security issue. GNU Social developers are working on a solution. In the meantime, if you really want your repeat/requeet to federate, you can always to a "manual repeat", i.e. write RQ @username, and then copy-paste the notice.
-Thanks to @simsa0 and @mcscx for their work on this FAQ.
+Thanks to @simsa0 and @mcscx for their work on this FAQ. Any errors are due to bad editing by @hannes2peer.
@@ -715,11 +715,19 @@ class QvitterAction extends ApiAction - - - - - + + + + + + '.QvitterPlugin::settings('js').''; + } + + ?>