More generic
This commit is contained in:
parent
d9af8529d2
commit
e8702fed67
|
@ -420,10 +420,10 @@ function mesh_firewall {
|
|||
|
||||
function mesh_tox_node {
|
||||
# obtain commits from the main file
|
||||
if [ -f /usr/loca/bin/freedombone ]; then
|
||||
TOX_COMMIT_MAIN=$(cat /usr/local/bin/freedombone | grep "TOX_COMMIT=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
if [ -f /usr/loca/bin/${PROJECT_NAME} ]; then
|
||||
TOX_COMMIT_MAIN=$(cat /usr/local/bin/${PROJECT_NAME} | grep "TOX_COMMIT=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
else
|
||||
TOX_COMMIT_MAIN=$(cat /usr/bin/freedombone | grep "TOX_COMMIT=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
TOX_COMMIT_MAIN=$(cat /usr/bin/${PROJECT_NAME} | grep "TOX_COMMIT=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
fi
|
||||
if [ ${#TOX_COMMIT_MAIN} -gt 10 ]; then
|
||||
TOX_COMMIT=$TOX_COMMIT_MAIN
|
||||
|
@ -433,10 +433,10 @@ function mesh_tox_node {
|
|||
exit 76325
|
||||
fi
|
||||
|
||||
if [ -f /usr/loca/bin/freedombone ]; then
|
||||
TOXID_REPO_MAIN=$(cat /usr/local/bin/freedombone | grep "TOXID_REPO=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
if [ -f /usr/loca/bin/${PROJECT_NAME} ]; then
|
||||
TOXID_REPO_MAIN=$(cat /usr/local/bin/${PROJECT_NAME} | grep "TOXID_REPO=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
else
|
||||
TOXID_REPO_MAIN=$(cat /usr/bin/freedombone | grep "TOXID_REPO=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
TOXID_REPO_MAIN=$(cat /usr/bin/${PROJECT_NAME} | grep "TOXID_REPO=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
fi
|
||||
if [ ${#TOXID_REPO_MAIN} -gt 5 ]; then
|
||||
TOXID_REPO=$TOXID_REPO_MAIN
|
||||
|
@ -446,10 +446,10 @@ function mesh_tox_node {
|
|||
exit 78252
|
||||
fi
|
||||
|
||||
if [ -f /usr/loca/bin/freedombone ]; then
|
||||
TOX_PORT_MAIN=$(cat /usr/local/bin/freedombone | grep "TOX_PORT=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
if [ -f /usr/loca/bin/${PROJECT_NAME} ]; then
|
||||
TOX_PORT_MAIN=$(cat /usr/local/bin/${PROJECT_NAME} | grep "TOX_PORT=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
else
|
||||
TOX_PORT_MAIN=$(cat /usr/bin/freedombone | grep "TOX_PORT=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
TOX_PORT_MAIN=$(cat /usr/bin/${PROJECT_NAME} | grep "TOX_PORT=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
fi
|
||||
if [ ${#TOX_PORT_MAIN} -gt 2 ]; then
|
||||
TOX_PORT=$TOX_PORT_MAIN
|
||||
|
@ -459,10 +459,10 @@ function mesh_tox_node {
|
|||
exit 32856
|
||||
fi
|
||||
|
||||
if [ -f /usr/loca/bin/freedombone ]; then
|
||||
TOX_REPO_MAIN=$(cat /usr/local/bin/freedombone | grep "TOX_REPO=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
if [ -f /usr/loca/bin/${PROJECT_NAME} ]; then
|
||||
TOX_REPO_MAIN=$(cat /usr/local/bin/${PROJECT_NAME} | grep "TOX_REPO=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
else
|
||||
TOX_REPO_MAIN=$(cat /usr/bin/freedombone | grep "TOX_REPO=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
TOX_REPO_MAIN=$(cat /usr/bin/${PROJECT_NAME} | grep "TOX_REPO=" | head -n 1 | awk -F "'" '{print $2}')
|
||||
fi
|
||||
if [ ${#TOX_REPO_MAIN} -gt 10 ]; then
|
||||
TOX_REPO=$TOX_REPO_MAIN
|
||||
|
|
Loading…
Reference in New Issue