Commit:    6f46af520aada97b857b4e5dbe4937167898a45e
Author:    Anatol Belski <[email protected]>         Sat, 19 Nov 2016 16:56:16 +0100
Parents:   ee40a45f9c453d9d464c8fb5a2c19d098310a373
Branches:  master

Link:       
http://git.php.net/?p=web/rmtools.git;a=commitdiff;h=6f46af520aada97b857b4e5dbe4937167898a45e

Log:
fix arch arg

Changed paths:
  M  script/snap.php


Diff:
diff --git a/script/snap.php b/script/snap.php
index 72ce792..ae47bfb 100644
--- a/script/snap.php
+++ b/script/snap.php
@@ -14,7 +14,11 @@ $new_rev = false;
 $branch_name = $argv[1];
 $build_type = strtolower($argv[2]);
 $force = isset($argv[3]) ? true : false;
-$config_path = __DIR__ . '/../data/config/branch/' . $branch_name . '.ini';
+$sdk_arch = getenv("PHP_SDK_ARCH");
+if (!$sdk_arch) {
+       throw new \Exception("Arch is empty, the SDK might not have been setup. 
");
+}
+$config_path = __DIR__ . '/../data/config/branch/' . $sdk_arch . '/' . 
$branch_name . '.ini';
 
 $branch = new rm\Branch($config_path);
 $branch->update();
@@ -23,7 +27,7 @@ $branch_name = $branch->config->getName();
 $branch_name_short = $branch->config->getBranch();
 $last_rev = $branch->getLastRevisionId();
 
-echo "Running <$config_path>\n";
+echo "Running <" . realpath($config_path) . ">\n";
 echo "\t$branch_name\n";
 echo "\tprevious revision was: " . $branch->getPreviousRevision() . "\n";
 echo "\tlast revision is: " . $branch->getLastRevisionId() . "\n";


--
PHP Webmaster List Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to