aboutsummaryrefslogtreecommitdiffhomepage
path: root/TODO
diff options
context:
space:
mode:
authorRobin Haberkorn <robin.haberkorn@googlemail.com>2024-12-30 05:00:44 +0300
committerRobin Haberkorn <robin.haberkorn@googlemail.com>2024-12-30 05:00:44 +0300
commite2eff00a9c0d89a196bb297b4958473a681ddfee (patch)
tree3260f9a583fae5f77563bc28e434bf23cf4075cd /TODO
parent45cb7da5de3145525c4f33605cb77e76854159a1 (diff)
downloadsciteco-e2eff00a9c0d89a196bb297b4958473a681ddfee.tar.gz
support +line[,column] and filename:line:column syntaxes when opening files
* This is done via the new opener.tes in the standard library. * Some programs that use $EDITOR expect the +line syntax to work. * You can copy filename:line:column directly from GCC error messages and filename:line from grep output. * Since there may be safe file names beginning with "+" or containing colons, there needs to be a way to turn this off, especially for scripts that don't know anything about the filenames to open. This is done with "--". Unfortunately, the first "--", that stops parameter processing, is always removed from the command line and not passed down into TECO land. This is not a problem for stand-alone scripts, since the script filename is already stopping option processing, so "--" would get passed down. But when calling the profile via `sciteco -- ...`, you could prevent leading minus signs to cause problems but since the `--` is removed, opener.tes cannot use it as a hint. Therefore, we introduced `-S` as a new alternative to `--`, that's always passed down as `--` (i.e. it is equivalent to "-- --"). In other words, `sciteco -S *` will always open exactly the specified files without any danger of misinterpreting certain file names. Should we ever switch to a custom option parsing algorithm, we might preserve "--" (unless after --mung) and thus get rid of "-S". * This advanced behavior can be tweaked by the user relatively easily. In the easiest case, we could replace M[opener] with <:L;R 0X.f [* @EB/^EN.f/ ]* L> in ~/.teco_ini to completely disable the special syntax.
Diffstat (limited to 'TODO')
-rw-r--r--TODO8
1 files changed, 0 insertions, 8 deletions
diff --git a/TODO b/TODO
index adaa334..dc85057 100644
--- a/TODO
+++ b/TODO
@@ -466,14 +466,6 @@ Features:
* Get into mentors.debian.net. First step to being adopted
into the Debian repositories.
* Get meta-rhaberkorn into https://layers.openembedded.org
- * sample.teco_ini: Support opening files on certain lines
- (filename:line).
- Theoretically, this could also be added to the <EB> syntax,
- although the colon character is allowed in filenames under Windows.
- In principe there is little need for that in interactive mode,
- but it would ease opening filenames copied from compiler errors
- or grep -n results.
- Other editors use the +line[,col] syntax (see nano).
* <:EF> for saving and closing a buffer, similar to <:EX>.
* Bash completions.
* FreeBSD: rctl(8) theoretically allows setting up per-process actions