|
151 | 151 | echo -en "checking ${remotereponame} config lgsm-template.cfg...\c"
|
152 | 152 | fn_script_log_info "Checking ${remotereponame} config lgsm-template.cfg"
|
153 | 153 | if [ "${remotereponame}" == "GitHub" ]; then
|
154 |
| - curl --connect-timeout 10 -IsfL "https://raw.githubusercontent.com/${githubuser}/${githubrepo}/${githubbranch}/lgsm/config-default/config-lgsm/lgsm-template.cfg" 1>/dev/null |
| 154 | + curl --connect-timeout 10 -IsfL "https://raw.githubusercontent.com/${githubuser}/${githubrepo}/${githubbranch}/lgsm/config-default/config-lgsm/lgsm-template.cfg" 1>/dev/null |
155 | 155 | else
|
156 |
| - curl --connect-timeout 10 -IsfL "https://bitbucket.org/${githubuser}/${githubrepo}/raw/${githubbranch}/lgsm/config-default/config-lgsm/lgsm-template.cfg" 1>/dev/null |
| 156 | + curl --connect-timeout 10 -IsfL "https://bitbucket.org/${githubuser}/${githubrepo}/raw/${githubbranch}/lgsm/config-default/config-lgsm/lgsm-template.cfg" 1>/dev/null |
157 | 157 | fi
|
158 | 158 | if [ $? != "0" ]; then
|
159 |
| - fn_print_fail_eol_nl |
160 |
| - fn_script_log_fatal "Checking ${remotereponame} config lgsm-template.cfg" |
161 |
| - fn_script_log_fatal "Curl returned error: $?" |
162 |
| - core_exit.sh |
| 159 | + fn_print_fail_eol_nl |
| 160 | + fn_script_log_fatal "Checking ${remotereponame} config lgsm-template.cfg" |
| 161 | + fn_script_log_fatal "Curl returned error: $?" |
| 162 | + core_exit.sh |
163 | 163 | fi
|
164 | 164 |
|
165 | 165 | if [ "${remotereponame}" == "GitHub" ]; then
|
166 |
| - config_file_diff=$(diff "${configdirdefault}/config-lgsm/lgsm-template.cfg" <(curl --connect-timeout 10 -s "https://raw.githubusercontent.com/${githubuser}/${githubrepo}/${githubbranch}/lgsm/config-default/config-lgsm/lgsm-template.cfg")) |
| 166 | + config_file_diff=$(diff "${configdirdefault}/config-lgsm/lgsm-template.cfg" <(curl --connect-timeout 10 -s "https://raw.githubusercontent.com/${githubuser}/${githubrepo}/${githubbranch}/lgsm/config-default/config-lgsm/lgsm-template.cfg")) |
167 | 167 | else
|
168 |
| - config_file_diff=$(diff "${configdirdefault}/config-lgsm/lgsm-template.cfg" <(curl --connect-timeout 10 -s "https://bitbucket.org/${githubuser}/${githubrepo}/raw/${githubbranch}/lgsm/config-default/config-lgsm/lgsm-template.cfg")) |
| 168 | + config_file_diff=$(diff "${configdirdefault}/config-lgsm/lgsm-template.cfg" <(curl --connect-timeout 10 -s "https://bitbucket.org/${githubuser}/${githubrepo}/raw/${githubbranch}/lgsm/config-default/config-lgsm/lgsm-template.cfg")) |
169 | 169 | fi
|
170 | 170 |
|
171 | 171 | if [ "${config_file_diff}" != "" ]; then
|
172 |
| - fn_print_update_eol_nl |
173 |
| - fn_script_log_update "Checking ${remotereponame} config lgsm-template.cfg" |
174 |
| - rm -f "${configdirdefault:?}/config-lgsm/lgsm-template.cfg" |
175 |
| - fn_fetch_file_github "lgsm/config-default/config-lgsm" "lgsm-template.cfg" "${configdirdefault}/config-lgsm" "nochmodx" "norun" "noforce" "nohash" |
| 172 | + fn_print_update_eol_nl |
| 173 | + fn_script_log_update "Checking ${remotereponame} config lgsm-template.cfg" |
| 174 | + rm -f "${configdirdefault:?}/config-lgsm/lgsm-template.cfg" |
| 175 | + fn_fetch_file_github "lgsm/config-default/config-lgsm" "lgsm-template.cfg" "${configdirdefault}/config-lgsm" "nochmodx" "norun" "noforce" "nohash" |
176 | 176 | else
|
177 |
| - fn_print_ok_eol_nl |
178 |
| - fn_script_log_pass "Checking ${remotereponame} config lgsm-template.cfg" |
| 177 | + fn_print_ok_eol_nl |
| 178 | + fn_script_log_pass "Checking ${remotereponame} config lgsm-template.cfg" |
179 | 179 | fi
|
180 | 180 |
|
181 | 181 | # Check distro csv. ${datadir}/${distroid}-${distroversioncsv}.csv
|
|
0 commit comments