File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ author="ton-blockchain"
1212repo=" mytonctrl"
1313branch=" master"
1414srcdir=" /usr/src/"
15- bindir =" /usr/bin /"
15+ tmpdir =" /tmp/mytonctrl_src /"
1616
1717# Get arguments
1818while getopts a:r:b: flag
2828COLOR=' \033[92m'
2929ENDC=' \033[0m'
3030
31- # Go to work dir
32- cd ${srcdir}
31+ mkdir -p ${tmpdir}
32+ cd ${tmpdir}
33+ rm -rf ${tmpdir} /${repo}
34+ echo " https://github.com/${author} /${repo} .git -> ${branch} "
35+ git clone --recursive https://github.com/${author} /${repo} .git || exit 1
3336
34- # uninstall previous version
3537rm -rf ${srcdir} /${repo}
3638pip3 uninstall -y mytonctrl
3739
3840# Update code
39- echo " https://github.com/ ${author} / ${repo} .git -> ${branch} "
40- git clone --recursive https://github.com/ ${author } /${repo} .git
41+ cd ${srcdir}
42+ cp -rf ${tmpdir } /${repo} ${srcdir}
4143cd ${repo} && git checkout ${branch}
4244pip3 install -U .
4345
You can’t perform that action at this time.
0 commit comments