Enforce function declaration format in bash8

Check that function calls look like ^function foo {$ in bash8, and fix
all existing failures of that check.  Add a note to HACKING.rst

Change-Id: Ic19eecb39e0b20273d1bcd551a42fe400d54e938
diff --git a/lib/trove b/lib/trove
index 6834149..75b990f 100644
--- a/lib/trove
+++ b/lib/trove
@@ -53,7 +53,7 @@
 }
 
 # setup_trove_logging() - Adds logging configuration to conf files
-function setup_trove_logging() {
+function setup_trove_logging {
     local CONF=$1
     iniset $CONF DEFAULT debug $ENABLE_DEBUG_LOG_LEVEL
     iniset $CONF DEFAULT use_syslog $SYSLOG
@@ -69,7 +69,7 @@
 # ------------------------------------------------------------------
 # service              trove     admin        # if enabled
 
-create_trove_accounts() {
+function create_trove_accounts {
     # Trove
     SERVICE_TENANT=$(openstack project list | awk "/ $SERVICE_TENANT_NAME / { print \$2 }")
     SERVICE_ROLE=$(openstack role list | awk "/ admin / { print \$2 }")
@@ -106,19 +106,19 @@
 
 # cleanup_trove() - Remove residual data files, anything left over from previous
 # runs that a clean run would need to clean up
-function cleanup_trove() {
+function cleanup_trove {
     #Clean up dirs
     rm -fr $TROVE_AUTH_CACHE_DIR/*
     rm -fr $TROVE_CONF_DIR/*
 }
 
 # configure_troveclient() - Set config files, create data dirs, etc
-function configure_troveclient() {
+function configure_troveclient {
     setup_develop $TROVECLIENT_DIR
 }
 
 # configure_trove() - Set config files, create data dirs, etc
-function configure_trove() {
+function configure_trove {
     setup_develop $TROVE_DIR
 
     # Create the trove conf dir and cache dirs if they don't exist
@@ -182,17 +182,17 @@
 }
 
 # install_troveclient() - Collect source and prepare
-function install_troveclient() {
+function install_troveclient {
     git_clone $TROVECLIENT_REPO $TROVECLIENT_DIR $TROVECLIENT_BRANCH
 }
 
 # install_trove() - Collect source and prepare
-function install_trove() {
+function install_trove {
     git_clone $TROVE_REPO $TROVE_DIR $TROVE_BRANCH
 }
 
 # init_trove() - Initializes Trove Database as a Service
-function init_trove() {
+function init_trove {
     #(Re)Create trove db
     recreate_database trove utf8
 
@@ -201,14 +201,14 @@
 }
 
 # start_trove() - Start running processes, including screen
-function start_trove() {
+function start_trove {
     screen_it tr-api "cd $TROVE_DIR; $TROVE_BIN_DIR/trove-api --config-file=$TROVE_CONF_DIR/trove.conf --debug 2>&1"
     screen_it tr-tmgr "cd $TROVE_DIR; $TROVE_BIN_DIR/trove-taskmanager --config-file=$TROVE_CONF_DIR/trove-taskmanager.conf --debug 2>&1"
     screen_it tr-cond "cd $TROVE_DIR; $TROVE_BIN_DIR/trove-conductor --config-file=$TROVE_CONF_DIR/trove-conductor.conf --debug 2>&1"
 }
 
 # stop_trove() - Stop running processes
-function stop_trove() {
+function stop_trove {
     # Kill the trove screen windows
     for serv in tr-api tr-tmgr tr-cond; do
         screen_stop $serv