nano-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Enhance nanorc man page wording


From: David
Subject: Enhance nanorc man page wording
Date: Thu, 16 Feb 2023 00:11:49 +0800

Hello Benno,

Lately, I was creating nano syntax highlighting files when I encountered a strange behavior. When I wrote:
syntax "test" "\.my_config$"
It correctly highlights the file /home/.my_config , but then failed when I added an anchor to it:
syntax "test" "^\.my_config$"
I looked up the man page over and over again, but it stated clearly that:

When nano is run, this syntax will be automatically activated if the current filename matches the extended regular _expression_ fileregex.

which means that it's the filename that matches the regex. In convention, filename is the basename including the extension, which is not the same as the full path name. This is where I found frustrated, as nano is in fact matching the full pathname instead! Therefore, I strongly suggest clarifying what filename actually means.

Thanks,
davidhcefx






reply via email to

[Prev in Thread] Current Thread [Next in Thread]