aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Fischer <bantu@phpbb.com>2011-01-25 19:07:29 +0100
committerAndreas Fischer <bantu@phpbb.com>2011-02-03 11:12:48 +0100
commit67fe441f7e94aa9f502f3f8d3ff7ad15bb2ae008 (patch)
treec5756e054683a0b6aed5aa2104ff9d5b79b56c51 /git-tools/setup_github_network.php
parent[ticket/9805] Better support for already existing repositories. (diff)
downloadphpbb-67fe441f7e94aa9f502f3f8d3ff7ad15bb2ae008.tar.gz
phpbb-67fe441f7e94aa9f502f3f8d3ff7ad15bb2ae008.tar.bz2
phpbb-67fe441f7e94aa9f502f3f8d3ff7ad15bb2ae008.zip
[ticket/9805] Move check lower down.
PHPBB3-9805
Diffstat (limited to 'git-tools/setup_github_network.php')
-rw-r--r--git-tools/setup_github_network.php13
1 files changed, 7 insertions, 6 deletions
diff --git a/git-tools/setup_github_network.php b/git-tools/setup_github_network.php
index f34787c4c4..911d336c2d 100644
--- a/git-tools/setup_github_network.php
+++ b/git-tools/setup_github_network.php
@@ -7,11 +7,6 @@
*
*/
-if ($argc < 2)
-{
- show_usage();
-}
-
function show_usage()
{
$filename = basename(__FILE__);
@@ -40,7 +35,13 @@ function show_usage()
}
// Handle arguments
-$opts = getopt('s:u:r:m:d');
+$opts = getopt('s:u:r:m:d');
+
+if (empty($opts))
+{
+ show_usage();
+}
+
$scope = get_arg($opts, 's', '');
$username = get_arg($opts, 'u', 'phpbb');
$repository = get_arg($opts, 'r', 'phpbb3');