joereynolds / SQHell.vim

An SQL wrapper for vim
MIT License
131 stars 9 forks source link

Friendlier warnings if configuration is not set/incorrect #14

Open joereynolds opened 6 years ago

joereynolds commented 6 years ago

currently we get this

Error detected while processing function mysql#ShowDatabases[1]..mysql#GetResultsFromQuery:
line    1:
E121: Undefined variable: g:sqh_connections
E15: Invalid expression: g:sqh_connections[g:sqh_connection]['user']
line    2:
E121: Undefined variable: g:sqh_connections
E15: Invalid expression: g:sqh_connections[g:sqh_connection]['password']
line    3:
E121: Undefined variable: g:sqh_connections
E15: Invalid expression: g:sqh_connections[g:sqh_connection]['host']
line    5:
E121: Undefined variable: user
E15: Invalid expression: 'mysql -u' . user . ' -p' . password . ' -h' . host
line    6:
E121: Undefined variable: connection_details
E15: Invalid expression: connection_details . " --table -e '" . a:command . "'"
line    7:
E121: Undefined variable: system_command
E116: Invalid arguments for function system
E15: Invalid expression: system(system_command)
line    8:
E121: Undefined variable: query_results
E15: Invalid expression: query_results
--No lines in buffer--
1 line less; before #1  1 seconds ago