`shfmt -i 2 -ci -sr`

pull/162/head
IceCodeNew 2020-10-02 20:32:56 +08:00
parent c1fb7038a1
commit ccd02ace75
1 changed files with 8 additions and 8 deletions

View File

@ -328,7 +328,7 @@ install_v2ray() {
fi
# Install V2Ray configuration file to $JSON_PATH
# shellcheck disable=SC2153
# shellcheck disable=SC2153
if [[ -z "$JSONS_PATH" ]] && [[ ! -d "$JSON_PATH" ]]; then
install -d "$JSON_PATH"
echo "{}" > "${JSON_PATH}/config.json"
@ -394,7 +394,7 @@ ExecStart=/usr/local/bin/v2ray -config ${JSON_PATH}/%i.json" > \
echo "${red}warning: ${green}The following are the actual parameters for the v2ray service startup."
echo "${red}warning: ${green}Please make sure the configuration file path is correctly set.${reset}"
systemd-analyze cat-config /etc/systemd/system/v2ray.service
# shellcheck disable=SC2154
# shellcheck disable=SC2154
if [[ x"${check_all_service_files:0:1}" = x'y' ]]; then
echo
echo
@ -451,12 +451,12 @@ remove_v2ray() {
stop_v2ray
fi
if ! ("rm" -r '/usr/local/bin/v2ray' \
'/usr/local/bin/v2ctl' \
"$DAT_PATH" \
'/etc/systemd/system/v2ray.service' \
'/etc/systemd/system/v2ray@.service' \
'/etc/systemd/system/v2ray.service.d' \
'/etc/systemd/system/v2ray@.service.d'); then
'/usr/local/bin/v2ctl' \
"$DAT_PATH" \
'/etc/systemd/system/v2ray.service' \
'/etc/systemd/system/v2ray@.service' \
'/etc/systemd/system/v2ray.service.d' \
'/etc/systemd/system/v2ray@.service.d'); then
echo 'error: Failed to remove V2Ray.'
exit 1
else