自动检测并下载 xray-core
This commit is contained in:
parent
dc58317f0f
commit
329b27403f
|
@ -49,6 +49,8 @@ Diy_Part1_Base() {
|
||||||
if [[ "${INCLUDE_HelloWorld}" == "true" ]];then
|
if [[ "${INCLUDE_HelloWorld}" == "true" ]];then
|
||||||
ExtraPackages git lean luci-app-vssr https://github.com/jerrykuku master
|
ExtraPackages git lean luci-app-vssr https://github.com/jerrykuku master
|
||||||
ExtraPackages git lean lua-maxminddb https://github.com/jerrykuku master
|
ExtraPackages git lean lua-maxminddb https://github.com/jerrykuku master
|
||||||
|
PKG_Finder d package xray-core
|
||||||
|
[[ -z "${PKG_RESULT}" ]] && ExtraPackages svn other xray-core https://github.com/fw876/helloworld/trunk
|
||||||
fi
|
fi
|
||||||
if [[ "${INCLUDE_Bypass}" == "true" ]];then
|
if [[ "${INCLUDE_Bypass}" == "true" ]];then
|
||||||
ExtraPackages git other luci-app-bypass https://github.com/garypang13 main
|
ExtraPackages git other luci-app-bypass https://github.com/garypang13 main
|
||||||
|
@ -163,6 +165,18 @@ Mkdir() {
|
||||||
unset _DIR
|
unset _DIR
|
||||||
}
|
}
|
||||||
|
|
||||||
|
PKG_Finder() {
|
||||||
|
unset PKG_RESULT
|
||||||
|
PKG_TYPE=${1}
|
||||||
|
PKG_DIR=${2}
|
||||||
|
PKG_NAME=${3}
|
||||||
|
[[ -z ${PKG_TYPE} ]] && [[ -z ${PKG_NAME} ]] || [[ -z ${PKG_DIR} ]] && return
|
||||||
|
PKG_RESULT=$(find -name ${PKG_DIR}/${PKG_NAME} -type ${PKG_TYPE} -exec echo {} \;)
|
||||||
|
if [[ ! -z "${PKG_RESULT}" ]];then
|
||||||
|
echo "[${PKG_NAME}] is detected,Dir: ${PKG_RESULT}"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
ExtraPackages() {
|
ExtraPackages() {
|
||||||
PKG_PROTO=${1}
|
PKG_PROTO=${1}
|
||||||
PKG_DIR=${2}
|
PKG_DIR=${2}
|
||||||
|
|
Loading…
Reference in New Issue