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

Bug#875531: "editor +42 filename" -- accept or reject?



Adam Borowski <kilobyte@angband.pl> writes:

> Now that you folks are dealing with the "editor" virtual package, and,
> what interests me here, the alternative for /usr/bin/editor -- could you
> please process this proposal as well, and either accept or close it?

> My point is that, all but one (e3) current alternatives allow
> positioning the cursor on a given line, and various users take
> inconsistent approach as to when this feature can be used.

Thank you for doing the research to confirm this is supported by all the
editor alternatives!  That makes this fairly easy.  Attached is a proposed
diff.  This is on top of the diff for #682347; it's separable, but I'd
prefer to get that seconded and merged first.

Note that, based on your research, this will make e3 RC-buggy.  (Obviously
this wouldn't be RC for this upcoming release.)

-- 
Russ Allbery (rra@debian.org)              <https://www.eyrie.org/~eagle/>

diff --git a/policy/ch-customized-programs.rst b/policy/ch-customized-programs.rst
index 27abebd..d58e297 100644
--- a/policy/ch-customized-programs.rst
+++ b/policy/ch-customized-programs.rst
@@ -93,6 +93,14 @@ alternative should have a slave alternative for
 ``/usr/share/man/man1/pager.1.gz`` pointing to the corresponding manual
 page.
 
+Packages that register as an alternative for ``/usr/bin/editor`` must
+support the following features:
+
+- When invoked as ``editor <filename>``, they open ``<filename>`` for
+  editing.
+- When invoked as ``editor +N <filename>``, they open ``<filename>`` for
+  editing and position the cursor or equivalent at line ``N`` of the file.
+
 Packages that register as an alternative for ``/usr/bin/editor`` should
 also provide the virtual package ``editor`` by including it in the
 ``Provides`` control field. The package providing the current default

Reply to: