+ # is that setting already present in file ?
+ if grep --extended-regexp -q "#?${param} *=.*" $postgresql_conf; then
+ sed --regexp-extended --in-place \
+ --expression="s|#?${param} = .*|${param} = ${value}|" \
+ $postgresql_conf
+ else
+ echo "${param} = ${value}" >> $postgresql_conf
+ fi