as.sh fix mingw support.

pull/483/head doc-3.0.4-20181128
hengyunabc 6 years ago
parent 3d9e066080
commit feedcb9556

14
as.sh

@ -8,10 +8,10 @@
# program : Arthas # program : Arthas
# author : Core Engine @ Taobao.com # author : Core Engine @ Taobao.com
# date : 2018-11-19 # date : 2018-11-23
# current arthas script version # current arthas script version
ARTHAS_SCRIPT_VERSION=3.0.4.2 ARTHAS_SCRIPT_VERSION=3.0.4.3
# define arthas's home # define arthas's home
ARTHAS_HOME=${HOME}/.arthas ARTHAS_HOME=${HOME}/.arthas
@ -488,10 +488,14 @@ attach_jvm()
echo "Attaching to ${TARGET_PID} using version ${1}..." echo "Attaching to ${TARGET_PID} using version ${1}..."
local opts="${ARTHAS_OPTS} ${BOOT_CLASSPATH} ${JVM_OPTS}" local java_command=("${JAVA_HOME}"/bin/java)
if [ "${BOOT_CLASSPATH}" ]; then
java_command+=("${BOOT_CLASSPATH}")
fi
if [ ${TARGET_IP} = ${DEFAULT_TARGET_IP} ]; then if [ ${TARGET_IP} = ${DEFAULT_TARGET_IP} ]; then
"${JAVA_HOME}"/bin/java \ "${java_command[@]}" \
${opts} \ ${ARTHAS_OPTS} ${JVM_OPTS} \
-jar "${arthas_lib_dir}/arthas-core.jar" \ -jar "${arthas_lib_dir}/arthas-core.jar" \
-pid ${TARGET_PID} \ -pid ${TARGET_PID} \
-target-ip ${TARGET_IP} \ -target-ip ${TARGET_IP} \

Loading…
Cancel
Save