Skip to content

Instantly share code, notes, and snippets.

@zentavr
Last active August 16, 2019 07:16
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zentavr/a6d74b31e93964f51e771287be94283e to your computer and use it in GitHub Desktop.
Save zentavr/a6d74b31e93964f51e771287be94283e to your computer and use it in GitHub Desktop.
Syntax files for Midnight Commander editor
# BGP Syntax file
#
# Author: Andrii Miroshnychenko <zentavr@linet.zp.ua>
wholechars abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_-[]^$
context default
keyword whole linestart hostname yellow
keyword whole linestart agentx yellow
keyword whole linestart password yellow
keyword whole linestart enable\spassword yellow
keyword whole linestart enable yellow
keyword whole linestart router yellow
keyword whole linestart neighbor yellow
keyword whole linestart network yellow
keyword whole linestart no\snetwork brightred
keyword whole linestart ip yellow
keyword whole linestart no\sip brightred
keyword whole linestart route-map yellow
keyword whole linestart log yellow
keyword whole linestart line yellow
keyword whole linestart distance yellow
keyword whole linestart aggregate-address yellow
keyword whole linestart no\saggregate-address brightred
keyword whole linestart redistribute yellow
#keyword whole linestart \[\t\s\]bgp brightcyan
keyword whole bgp brightcyan
#keyword whole linestart \[\t\s\]match brightcyan
keyword whole match brightcyan
#keyword whole linestart \[\t\s\]set brightcyan
keyword whole set brightcyan
keyword whole call brightcyan
keyword whole description brightcyan
keyword whole on-match brightmagenta
keyword whole permit brightgreen
keyword whole deny red
# Comments
context exclusive ! \n brown
context exclusive bgp \n
keyword whole router-id white
keyword whole log-neighbor-changes white
keyword whole bestpath white
keyword whole dampening white
keyword whole deterministic-med white
keyword whole always-compare-med white
keyword whole cluster-id white
keyword whole multiple-instance white
keyword whole route-reflector\sallow-outbound-policy white
keyword whole as-path yellow
keyword whole \[1234567890\].\[1234567890\].\[1234567890\].\[1234567890\] brightcyan
keyword whole \[1234567890\] brightblue
context exclusive match \n
keyword whole as-path white
keyword whole community white
keyword whole ip\saddress white
keyword whole extcommunity white
keyword whole metric white
keyword whole origin white
keyword whole peer white
keyword whole tag white
keyword whole probability white
keyword whole prefix-list cyan
keyword whole exact-match yellow
keyword whole rt yellow
keyword whole soo yellow
keyword whole \[1234567890\] brightblue
context exclusive set \n
keyword whole as-path white
keyword whole community white
keyword whole comm-list white
keyword whole extcommunity white
keyword whole weight white
keyword whole local-preference white
keyword whole prepend\slast-as yellow
keyword whole prepend yellow
keyword whole none brightblue black
keyword whole additive brightmagenta
keyword whole delete red
keyword whole \[1234567890\] brightblue
context exclusive router\sbgp \n
keyword whole bgp green
keyword whole view yellow
keyword whole \[1234567890\] brightblue
context exclusive distance\sbgp \n
keyword whole bgp green
context exclusive redistribute \n
keyword whole kernel white
keyword whole static white
keyword whole connected white
keyword whole rip white
keyword whole ospf white
context exclusive neighbor \n
keyword whole description gray
keyword whole remote-as brightgreen
keyword whole timers\sconnect white
keyword whole timers white
keyword whole send-community white
keyword whole soft-reconfiguration white
keyword whole update-source white
keyword whole next-hop-self white
keyword whole ebgp-multihop white
keyword whole peer-group white
keyword whole version white
keyword whole capability white
keyword whole interface white
keyword whole port white
keyword whole weight white
keyword whole maximum-prefix white
keyword whole local-as white
keyword whole ttl-security\shops white
keyword whole peer-group white
keyword whole strict-capability-match white
keyword whole dont-capability-negotiate white
keyword whole override-capability white
keyword whole route-reflector-client white
keyword whole shutdown red
keyword whole default-originate brightred
# Filtering
keyword whole route-map yellow
keyword whole distribute-list yellow
keyword whole prefix-list yellow
keyword whole filter-list yellow
keyword whole in cyan
keyword whole out magenta
keyword whole \[1234567890\].\[1234567890\].\[1234567890\].\[1234567890\] brightcyan
keyword whole \[1234567890\] brightblue
context exclusive network \n
keyword whole \[1234567890\].\[1234567890\].\[1234567890\].\[1234567890\]/\[1234567890\] brightcyan
keyword whole \[1234567890\].\[1234567890\].\[1234567890\].\[1234567890\] brightcyan
context exclusive log \n
keyword whole file white
context exclusive ip \n
keyword whole as-path white
keyword whole prefix-list white
keyword whole community-list white
keyword whole extcommunity-list white
keyword whole description gray
keyword whole access-list brightcyan
keyword whole standard yellow
keyword whole expanded yellow
keyword whole permit brightgreen
keyword whole deny red
keyword whole le black white
keyword whole ge black white
keyword whole lt black white
keyword whole gt black white
keyword whole eq black white
keyword whole seq magenta
keyword whole \[1234567890\].\[1234567890\].\[1234567890\].\[1234567890\] brightcyan
keyword whole \[1234567890\] brightblue
# Add to your Syntax file *BEFORE*:
file .\* unknown
include unknown.syntax
# The next lines:
file bgpd\.conf$ BGP\sSyntax
include bgp.syntax
@zentavr
Copy link
Author

zentavr commented Oct 14, 2017

This hint allows you to see the pretty view of the quagga's bgpd.conf file

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment