#!/usr/bin/env php . */ define('INSTALLDIR', realpath(dirname(__FILE__) . '/..')); $shortoptions = 'i::n::y'; $longoptions = array('id=', 'nickname=', 'yes'); $helptext = <<group_id); } else { print "You must provide either an ID or a nickname.\n"; print "\n"; print $helptext; exit(1); } if (!have_option('y', 'yes')) { print "About to PERMANENTLY delete group '{$group->nickname}' ({$group->id}). Are you sure? [y/N] "; $response = fgets(STDIN); if (strtolower(trim($response)) != 'y') { print "Aborting.\n"; exit(0); } } print "Deleting..."; $group->delete(); print "DONE.\n";