You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficcontrol.apache.org by da...@apache.org on 2016/10/20 19:11:38 UTC
[08/17] incubator-trafficcontrol git commit: diff calc for functions
path
diff calc for functions path
Project: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/commit/f0d49388
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/tree/f0d49388
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/diff/f0d49388
Branch: refs/heads/master
Commit: f0d49388ca436d0988821e2cadd9f2007c0ff067
Parents: 71edde8
Author: Dan Kirkwood <da...@gmail.com>
Authored: Tue Oct 18 15:03:44 2016 -0600
Committer: Dan Kirkwood <da...@gmail.com>
Committed: Wed Oct 19 08:26:56 2016 -0600
----------------------------------------------------------------------
traffic_ops/experimental/ui/build/build_rpm.sh | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/f0d49388/traffic_ops/experimental/ui/build/build_rpm.sh
----------------------------------------------------------------------
diff --git a/traffic_ops/experimental/ui/build/build_rpm.sh b/traffic_ops/experimental/ui/build/build_rpm.sh
index c6ae21a..d9a2fc7 100755
--- a/traffic_ops/experimental/ui/build/build_rpm.sh
+++ b/traffic_ops/experimental/ui/build/build_rpm.sh
@@ -17,9 +17,12 @@
function importFunctions() {
local script=$(readlink -f "$0")
+ local suff=${script##*control/}
+ local tcdirlen=$[${#script} - ${#suff}]
+ export TC_DIR=${script:0:$tcdirlen}
local scriptdir=$(dirname "$script")
export TS_DIR=$(dirname "$scriptdir")
- export TC_DIR=$(dirname "$TS_DIR")
+
functions_sh="$TC_DIR/build/functions.sh"
if [[ ! -r $functions_sh ]]; then
echo "error: can't find $functions_sh"