dgethings / lsp-cisco-ios

Language Server for Cisco IOS
3 stars 0 forks source link

show only autocompletes for config relevant to the current mode #5

Open dgethings opened 2 months ago

dgethings commented 2 months ago

Currently the autocomplete shows all config keywords all the time. Limit the available autocomplete keywords to the keywords in the current "mode" (as described in the Cisco documentation).

Pay attention to modes that don't include the mode prompt (as you would see on a Cisco device). Pay attention to keywords that appear in more than one mode.

dgethings commented 2 months ago

Here are all the modes to cater for All configuration modes Archive config mode; log config (configuration change logger) submode (config-archive-log-cfg)# Archive configuration (config-archive) Configuration change logger configuration (config-archive-log-config) Global configuration Global configuration (config#) Global configuration (config) Interface configuration Interface configuration (config-if) Interface configuration Frame Relay DLCI configuration Template configuration (config-template) Interface configuration mode Line configuration Line configuration (config-line) MST configuration (config-mst) Redundancy configuration (config-r) Main CPU redundancy configuration (config-r-mc) Redundancy configuration (config-red) Time-range configuration (config-time-range) User EXEC Privileged EXEC All configuration modes log config (configuration-change logger) submode (config-archive-log-cfg)#