aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/fix_nt_symbol_path.sh
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2017-04-16 06:50:58 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2017-04-16 06:50:58 +0300
commitb865ceec9035f6b7b4b22a494d3f4c0d8ec31018 (patch)
tree31d1a8e29fc3ea1382428d7c16544458a423c6b4 /fix_nt_symbol_path.sh
parentrefactoring (diff)
downloadwindows-tmp-master.tar.gz
windows-tmp-master.zip
add a comment about a trickHEADmaster
It allows to safely split a string.
Diffstat (limited to 'fix_nt_symbol_path.sh')
-rwxr-xr-xfix_nt_symbol_path.sh2
1 files changed, 2 insertions, 0 deletions
diff --git a/fix_nt_symbol_path.sh b/fix_nt_symbol_path.sh
index 92e1de0..253513b 100755
--- a/fix_nt_symbol_path.sh
+++ b/fix_nt_symbol_path.sh
@@ -56,6 +56,8 @@ path_contains() {
local -a env_paths
local env_path
+ # Thanks to this guy for this trick:
+ # http://stackoverflow.com/a/24426608/514684
IFS="$path_separator" read -a env_paths -d '' -r < <( printf -- "%s$path_separator\\0" "$env_value" )
for env_path in ${env_paths[@]+"${env_paths[@]}"}; do