diff --git a/create-conty.sh b/create-conty.sh index 3fd4bd1..157c32b 100755 --- a/create-conty.sh +++ b/create-conty.sh @@ -61,8 +61,22 @@ else fi if [ ! -f "${utils}" ] || [ "$(wc -c < "${utils}")" -lt 100000 ]; then - rm -f "${utils}" - curl -#LO "https://github.com/Kron4ek/Conty/raw/master/${utils}" + if [ -d .git ]; then + git lfs install + git lfs fetch origin master + git lfs checkout + fi + + if [ ! -f "${utils}" ] || [ "$(wc -c < "${utils}")" -lt 100000 ]; then + if git config --get remote.origin.url; then + utils_url="$(git config --get remote.origin.url)"/raw/master/${utils} + else + utils_url="https://github.com/Kron4ek/Conty/raw/master/${utils}" + fi + + rm -f "${utils}" + curl -#LO "${utils_url}" + fi fi if [ ! -f conty-start.sh ]; then