$taguribase = TagURI::base();
$id = "tag:$taguribase:Groups";
$link = common_local_url('groups');
- // TRANS: Message is used as a subtitle when listing the lastest 20 groups. %s is a site name.
+ // TRANS: Message is used as a subtitle when listing the latest 20 groups. %s is a site name.
$subtitle = sprintf(_("groups on %s"), $sitename);
switch($this->format) {
if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); }
define('STATUSNET_BASE_VERSION', '1.0.0');
-define('STATUSNET_LIFECYCLE', 'dev'); // 'dev', 'alpha[0-9]+', 'beta[0-9]+', 'rc[0-9]+', 'release'
+define('STATUSNET_LIFECYCLE', 'alpha1'); // 'dev', 'alpha[0-9]+', 'beta[0-9]+', 'rc[0-9]+', 'release'
define('STATUSNET_VERSION', STATUSNET_BASE_VERSION . STATUSNET_LIFECYCLE);
define('LACONICA_VERSION', STATUSNET_VERSION); // compatibility
define('INSTALLDIR', realpath(dirname(__FILE__) . '/../../..'));
+$longoptions = array('unsub');
+$shortoptions = 'u';
+
$helptext = <<<END_OF_HELP
resub-feed.php [options] http://example.com/atom-feed-url
Reinitialize the PuSH subscription for the given feed. This may help get
things restarted if we and the hub have gotten our states out of sync.
+Options:
+
+ -u --unsub Unsubscribe instead of subscribing.
END_OF_HELP;
showSub($sub);
print "\n";
-print "Pinging hub $sub->huburi with new subscription for $sub->uri\n";
-$ok = $sub->subscribe();
+
+if (have_option('u') || have_option('--unsub')) {
+ print "Pinging hub $sub->huburi with unsubscription for $sub->uri\n";
+ $ok = $sub->unsubscribe();
+} else {
+ print "Pinging hub $sub->huburi with new subscription for $sub->uri\n";
+ $ok = $sub->subscribe();
+}
if ($ok) {
print "ok\n";