Details
-
Improvement
-
Status: Closed
-
Trivial
-
Resolution: Fixed
-
1.4.1
-
None
Description
abc/abo/commit/optimize/readercycle scripts have the following identical snippet to set curl_url:
if [[ -n ${solr_url} ]] then curl_url=${solr_url} else if [[ -z ${solr_port} ]] then echo "Solr port number missing in $confFile or command line." echo "$USAGE" exit 1 fi # use default hostname if not specified if [[ -z ${solr_hostname} ]] then solr_hostname=localhost fi # use default webapp name if not specified if [[ -z ${webapp_name} ]] then webapp_name=solr fi curl_url=http://${solr_hostname}:${solr_port}/${webapp_name}/update fi
I think it should be moved to scripts-util in order to improve readability/maintainability.