From 076eb6f6af1454dd2635e1186cbe730a74306f7d Mon Sep 17 00:00:00 2001 From: Benno Schulenberg Date: Mon, 2 Dec 2019 17:00:35 +0100 Subject: [PATCH] docs: mention that a negative number after "+" counts from the end A negative line number given on the command line counts from the end of the relevant file (-1 meaning the first line from the bottom), and a negative column number from the end of the relevant line. The feature was added in version 2.8.5 but not mentioned in the manual. This addresses https://savannah.gnu.org/bugs/?57342. Suggested-by: Andreas Schamanek --- doc/nano.1 | 1 + doc/nano.texi | 1 + 2 files changed, 2 insertions(+) diff --git a/doc/nano.1 b/doc/nano.1 index e81927ec..879b7670 100644 --- a/doc/nano.1 +++ b/doc/nano.1 @@ -44,6 +44,7 @@ syntax coloring, line numbering, and soft-wrapping overlong lines. When giving a filename on the command line, the cursor can be put on a specific line by adding the line number with a plus sign (\fB+\fR) before the filename, and even in a specific column by adding it with a comma. +(Negative numbers count from the end of the file or line.) The cursor can be put on the first or last occurrence of a specific string by specifying that string after \fB+/\fR or \fB+?\fR before the filename. The string can be made case sensitive and/or caused to be interpreted as a diff --git a/doc/nano.texi b/doc/nano.texi index 79a7e669..93d25bb1 100644 --- a/doc/nano.texi +++ b/doc/nano.texi @@ -128,6 +128,7 @@ section), and to edit several files in a row. Additionally, the cursor can be put on a specific line of a file by adding the line number with a plus sign before the filename, and even in a specific column by adding it with a comma. +(Negative numbers count from the end of the file or line.) The cursor can also be put on the first or last occurrence of a specific string by specifying that string after @code{+/} or @code{+?} before the filename. The string can be made case sensitive and/or caused to be interpreted as a