Package: nano
Version: 2.7.1-1
Severity: wishlist
Tags: patch

Dear nano maintainers,

thanks for working in my editor of choice. It's really appreciated.

I tried to generate a patch for the nftables syntax highlighting, but failed
to find the source repo (the current git link from the tracker points to an
empty repository).

So, please, would you take the new file from here the file and push it
yourself?:

https://raw.githubusercontent.com/aborrero/nftables-nano-syntax/master/nftables.nanorc

========== 8< ==========
## Here is an example for nftables.

syntax "nftables" "\.(nft|nftables)$"
header "^#!.*(nft|nftables)"
comment "#"

# Objects and operations
color green "\<(chain|hook|policy|priority|ruleset|set|table|type|v?map)\>"
color green "\<(define|include)\>"
color red "\<(add|delete|flush|insert|remove|replace)\>"

# Families
color yellow "\<(arp|bridge|inet|netdev|ingress|ip6?)\>"

# Terminal statements
color red "\<(drop|reject)\>"
color brightblue "\<(accept|continue|(d|s)nat|goto|jump|masquerade|return)\>"

# Comments
color cyan "(^|[[:space:]])#.*$"

# Trailing whitespace
color ,green "[[:space:]]+$"

# Strings and others
color yellow ""(\\.|[^"])*"" "'(\\.|[^'])*'"
color green "[{}():;|`$<>!=&\\]" "(\]|\[)"

# Basic variable names
color brightred "\$[[:alpha:]_-][[:alnum:]_.-]*"
color brightred "\@[[:alpha:]_-][[:alnum:]_.-]*"
========== 8< ==========

Reply via email to