Re: [feature] Add edscript as a shortcut for running ed with script?

2024-10-02 Thread Antonio Diaz Diaz
Artyom Bologov wrote: The issue of scripting ed is still relevant though. Do you mean something like this: $ cat edscript #! /bin/sh ed "$2" < "$1" Best regards, Antonio.

Re: [feature] Add edscript as a shortcut for running ed with script?

2024-09-30 Thread Antonio Diaz Diaz
Hi Artyom, Artyom Bologov wrote: I'm using ed for scripting text modification lately. And what often bugs me is that scripting is so inconvenient with ed. Have you considered using sed? sed -i -f script.txt input.txt You may then alias (s)edscript as Alexander suggested: alias sedscript

Re: ed -p '' errors, but shouldn't

2024-06-14 Thread Antonio Diaz Diaz
Alexander Jones wrote: We should also consider that Arg_parser (where the issue originates) is used by more than just ed. I use it for my personal C/C++ projects, and other consumers may need null-string arguments. Glad to know that someone found Arg_parser useful. :-) I wrote Arg_parser to on

Re: ed -p '' errors, but shouldn't

2024-06-13 Thread Antonio Diaz Diaz
Antonio Diaz Diaz wrote: Note that empty option-arguments are ambiguous. See item 2a of section '12.1 Utility Argument Syntax': Now that the ambiguity has been solved[1], the question remains of whether accepting an empty prompt string is useful or is just an indirect way of disab

Re: ed -p '' errors, but shouldn't

2024-06-09 Thread Antonio Diaz Diaz
Emanuele Torre wrote: On Sat, Jun 08, 2024 at 07:33:23PM +0200, Antonio Diaz Diaz wrote: Note that empty option-arguments are ambiguous. See item 2a of section '12.1 Utility Argument Syntax': https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap12.html#tag_12_01

Re: ed -p '' errors, but shouldn't

2024-06-08 Thread Antonio Diaz Diaz
Hello Emanuele, Emanuele Torre wrote: I have noticed that ed -p '' errors with the following error. Thank you for reporting this, and for your accurate diagnostic of the cause of the behavior of ed. That seems incorrect; there does not seem to be anything in the POSIX Issue 7 specificati

GNU ed 1.20.2 released

2024-04-25 Thread Antonio Diaz Diaz
I am somewhat ashamed to announce the release of GNU ed 1.20.2. GNU ed is a line-oriented text editor. It is used to create, display, modify and otherwise manipulate text files, both interactively and via shell scripts. A restricted version of ed, red, can only edit files in the current direct

Re: g/x/s/x/x prints every substituted line twice

2024-04-22 Thread Antonio Diaz Diaz
Hello, Douglas McIlroy wrote: observed in versions 1.18 and 1.20.1 Thank you very much for reporting this. When I implemented case-insensitive REs in 1.18 I made a stupid mistake (fail to skip the newline when the last delimiter is omitted) that resulted in the defect you reported. I'll r

Re: GNU ed 1.20 released

2024-02-14 Thread Antonio Diaz Diaz
Marco Atzeri wrote: On 06/02/2024 19:42, jack...@fastmail.com wrote: As several experienced ed users have complained about this, I have removed the feature. Thank-you Where is possible to download the commit that removed the feature? You may download version 1.20.1, with the feature removed

Re: GNU ed 1.20 released

2024-02-13 Thread Antonio Diaz Diaz
Andrew Moore wrote: Do you mean executing at startup a '.n', '.l', or '.p' command when setting the current line in the command line, or something else? Yes, execute a `p' command (and only that) after setting dot when ed is invoked with the command-line option `+N' or '+/RE/' or `+?RE?'. And s

Re: GNU ed 1.20 released

2024-02-06 Thread Antonio Diaz Diaz
Hi Andrew, Andrew Moore wrote: GNU ed can now be used again as a systemd editor. Hurrah! Thank you! You are welcome. :-) One suggestion: it might be helpful, in addition to setting dot, to print dot. In the particular case of `systemctl edit`, the user doesn't manually invoke `ed +4 ...', so

GNU ed 1.20 released

2024-01-22 Thread Antonio Diaz Diaz
I am pleased to announce the release of GNU ed 1.20. GNU ed is a line-oriented text editor. It is used to create, display, modify and otherwise manipulate text files, both interactively and via shell scripts. A restricted version of ed, red, can only edit files in the current directory and can

Re: A one line change I wish to see by default.

2023-12-11 Thread Antonio Diaz Diaz
Andrew L. Moore wrote: Antonio wrote: ] So I guess the proposed "\x1B[A\r\x1B[J" may work for ed. NO. FWIW, I don't like the idea of adding ANSI escape sequences to ed and I would prefer not to add them unless there is a compelling reason to do so. (And even then, enabled with an option, not

Re: Warn when editing read-only files

2023-12-11 Thread Antonio Diaz Diaz
Andrew L. Moore wrote: Antonio Diaz Diaz writes: ] How do you propose to implement such a warning while remaining ] POSIX-compliant? In github.com/slewsys/ed this is implemented by reporting 'Read-only' if ed is in verbose mode: $ ed -v /etc/os-release /etc/os-release: File is rea

[Bug-ed] GNU ed 1.20-pre3 released

2023-11-27 Thread Antonio Diaz Diaz
GNU ed 1.20-pre3 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.20-pre3.tar.lz The sha256sum is: 813cb9c80e7d3b641e72fdf26909641967c2bacd70168bafcdc52c5e2f5035e5 ed-1.20-pre3.tar.lz Please, test it and report any bugs you find. GNU ed is a line-oriented text edito

Re: Warn when parent directory doesn't exist

2023-11-24 Thread Antonio Diaz Diaz
Paul Jackson wrote: What about making ed create the missing intermediate directories Do you mean as in: !mkdir -p foo/goo.dir Yeah - I know - old school geek here - feel free to ignore. But for less knowledgeable users, making ed automatically create any missing intermediate directori

Re: Warn when parent directory doesn't exist

2023-11-23 Thread Antonio Diaz Diaz
Dan Jacobson wrote: We got the same initial warning, but we need another initial warning: "Parent directory doesn't exist." Otherwise we think we will be able to write when the time comes to do so, but will be alarmed when we can't. What about making ed create the missing intermediate directori

Re: Warn when editing read-only files

2023-11-22 Thread Antonio Diaz Diaz
John Cowan wrote: On Fri, Nov 17, 2023 at 7:59 AM Antonio Diaz Diaz wrote: So this should be doable in GNU ed as soon as we find a way to reset the 'read_only' flag. Maybe by changing the name of the file with 'f'? Since ed does not have a 'set' command, to e

Re: Warn when editing read-only files

2023-11-20 Thread Antonio Diaz Diaz
Antonio Diaz Diaz wrote: John Cowan wrote: It would be nice if ed understood ~ in pathnames, however. This should be doable, as ed already uses HOME to save ed.hup in the user's home directory. Also, POSIX seems to say nothing against (or about) expanding '~' to $HOME in

Re: Warn when editing read-only files

2023-11-17 Thread Antonio Diaz Diaz
Dan Jacobson wrote: "PJ" == Paul Jackson writes: PJ> might have intended only to read a file, not write it OK, no warning then upon opening a read only file. Fine. But ah ha, how about a warning upon using a "a" or "i" etc. command? The other editor I maintain (GNU moe) does exactly this;

Re: Warn when editing read-only files

2023-11-16 Thread Antonio Diaz Diaz
Dan Jacobson wrote: Because ed does not warn when editing other peoples' files, when it comes time to save the file, one might realize there is nowhere to save it! How do you propose to implement such a warning while remaining POSIX-compliant? (See 'Edit Command' at https://pubs.opengroup.org

Re: potential inconsistency with buffer modified flag

2023-11-14 Thread Antonio Diaz Diaz
Eric Blake wrote: Maybe all the commands that can't change the buffer contents, namely f, h, H, k, l, n, p, P, #, =, and the null command, could be allowed in between a notification that a buffer was modified and a followup attempt to quit. I'm willing to implement such a change. Existing pract

Re: potential inconsistency with buffer modified flag

2023-11-11 Thread Antonio Diaz Diaz
Eric Blake wrote: Some other things we noted today: GNU ed treats 'r /dev/null' (or any other 0-byte file) as a command that does not modify the buffer changed status. Conversely, ed on MacOS treats the buffer as modified even when zero bytes are read. On that front, the POSIX folks were okay w

Re: A one line change I wish to see by default.

2023-11-09 Thread Antonio Diaz Diaz
Martin Guy wrote: On 06/11/2023, Antonio Diaz Diaz wrote: Zeke Williams wrote: Would there be any additional gotchas (Other than it won't work with non-ANSI terminals) to using "\x1B[A\r\x1B[J" to work around so to speak not using ncurses So I guess the proposed "\x1B

Re: potential inconsistency with buffer modified flag

2023-11-09 Thread Antonio Diaz Diaz
Eric Blake wrote: During today's Austin Group meeting (the folks working on POSIX), we noticed an inconsistency in GNU ed when compared to other implementations. It seems that ALL implementations we tested allow 'q' to quit immediately after an 'e' that failed because the buffer still has unwrit

Re: A one line change I wish to see by default.

2023-11-06 Thread Antonio Diaz Diaz
Zeke Williams wrote: Would there be any additional gotchas (Other than it won't work with non-ANSI terminals) to using "\x1B[A\r\x1B[J" to work around so to speak not using ncurses, which is what vim's version of ex uses to keep the prompt always at the bottom of the screen with any text from the

Re: Bug introduced in ed v1.14 (up to v1.19) corrupting full file which delta changes are applied to

2023-10-03 Thread Antonio Diaz Diaz
Alexander Jones wrote: "You are taking the deltas from the standard output of ed, which is for human consumption, not to be used as output to be written to a file." The deltas in question are generated with diff -e to produce the ed output. I think he meant the reconstructed files, after the

Re: Bug introduced in ed v1.14 (up to v1.19) corrupting full file which delta changes are applied to

2023-10-03 Thread Antonio Diaz Diaz
Hello Danie, Danie Theron - DSV wrote: This is working fine up to v1.13 of "ed", but since v1.14 up to the latest version v1.19, the deltas are not being applied correctly causing corruption in the reconstruction of programs. You are taking the deltas from the standard output of ed, which is f

Re: A suggestion to add to gnu ed: command line option to start on line foo or bar.

2023-04-13 Thread Antonio Diaz Diaz
Andrew L. Moore wrote: This has been supported by ed for nearly 50 years. Adding a new flag doesn't provide any new functionality, but it does break portability. Having said that, if Antonio chooses to add an explicit flag, please let it be something other than '-e', which is already used by sed

Re: Locale support

2023-03-08 Thread Antonio Diaz Diaz
Hi Alexander, Alexander Jones wrote: According to the README, locale(3) support is listed as an omission. I see a setlocale call at main.c:207, but POSIX does specify particular handling of locale-related environment variables that ed ignores. For reference, FreeBSD removed that line from their

Re: A suggestion to add to gnu ed: command line option to start on line foo or bar.

2023-03-08 Thread Antonio Diaz Diaz
John Cowan wrote: I have some other fairly small wish-list items for consideration as ed features. I think your definition of "fairly small wish-list item" differs from mine. ;-) As you surely know, ed is mostly of historical interest. Therefore implementing new features is not a priority. I

[Bug-ed] GNU ed 1.20-pre2 released

2023-03-02 Thread Antonio Diaz Diaz
GNU ed 1.20-pre2 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.20-pre2.tar.lz The sha256sum is: 6c74c378c85534da37aaa0cda0135a040f831c36b8589a5f40d713bc050f82c6 ed-1.20-pre2.tar.lz Please, test it and report any bugs you find. GNU ed is a line-oriented text edito

Re: A suggestion to add to gnu ed: command line option to start on line foo or bar.

2023-03-01 Thread Antonio Diaz Diaz
John Cowan wrote: I have some other fairly small wish-list items for consideration as ed features. Where should I put them; on this mailing list, or elsewhere? This list is fine.

Re: A suggestion to add to gnu ed: command line option to start on line foo or bar.

2023-02-28 Thread Antonio Diaz Diaz
John Cowan wrote: I agree that ed should perhaps behave differently in the interactive and scripted cases, but I think we can use the existing option '-l, --loose-exit-status' to ignore a mismatch in the interactive case instead of using a new option to force an error in the scripted case. Per

Re: A suggestion to add to gnu ed: command line option to start on line foo or bar.

2023-02-28 Thread Antonio Diaz Diaz
John Cowan wrote: In addition I have also implemented +?pattern to set the current line to the *last* line matching the pattern. Good feature; it is also present in 'ex'. I took the idea from GNU nano. I have never used 'ex' and all the information I have about 'ex' comes from its POSIX page

Re: A suggestion to add to gnu ed: command line option to start on line foo or bar.

2023-02-27 Thread Antonio Diaz Diaz
Matthew Polk wrote: I like ed. I think it's a cool editor. One thing that in my opinion to make it more usable with other programs would be to have implemented, is a command line option to have ed automatically start at the specified line rather than at the very bottom. John Cowan wrote: I wou

Re: 1.19 check fails on cygwin

2023-02-21 Thread Antonio Diaz Diaz
Hello Marco, Marco Atzeri wrote: $ cat /pub/devel/ed/tmp/ed-1.19/tmp/w.log \x2dhyphen\x2dprefixed\x2dfile: No such file or directory I am not familiar with this escape "\x2dhyphen\x2dprefixed\x2dfile" what is the expectation on Unix system ? '\x2d' is the hexadecimal escape sequence correspon

Re: A suggestion to add to gnu ed: command line option to start on line foo or bar.

2023-02-19 Thread Antonio Diaz Diaz
John Cowan wrote: Sounds good to me, but I don't have the time/energy to write the code at the moment. Don't worry. :-) I'll take care at least of the +n part. Just now don't have time for a more elaborate answer. Best regards, Antonio.

Re: keys.gnupg.net no longer resolves (was GNU ed 1.19 released)

2023-01-18 Thread Antonio Diaz Diaz
Hi David, David (Plasma) Paul wrote: The keys.gnupg.net domain no longer resolves. Would you please make your key available on another keyserver? Thank you very much for reporting this. I'll fix it in announcements of new releases. As Alexander Jones already noted, you should be able to fin

GNU ed 1.19 released

2023-01-14 Thread Antonio Diaz Diaz
I am pleased to announce the release of GNU ed 1.19. GNU ed is a line-oriented text editor. It is used to create, display, modify and otherwise manipulate text files, both interactively and via shell scripts. A restricted version of ed, red, can only edit files in the current directory and can

Re: [Bug-ed] GNU ed 1.19-rc1 released

2022-12-16 Thread Antonio Diaz Diaz
Sam James wrote: I understand. It's just awkward to then package using the packaging we have [...] if a package is set up for PGP signing. I was hoping it'd be easy to add one in. I may just wait until 1.19 is out. If I understand it correctly, it is easier for me to upload a .sig file than f

Re: [Bug-ed] GNU ed 1.19-rc1 released

2022-12-15 Thread Antonio Diaz Diaz
Hi Sam, Sam James wrote: Could you upload a .sig too? Thanks. Note that ed-1.19-rc1 is just a release candidate published only at Savannah, not at ftp.gnu.org. Pre-releases and RCs are meant for testing, not for full distribution. I delete them after the stable version is released, and I ne

[Bug-ed] GNU ed 1.19-rc1 released

2022-12-12 Thread Antonio Diaz Diaz
GNU ed 1.19-rc1 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.19-rc1.tar.lz The sha256sum is: a72480569979c1ed62bdeaddd10bf043fb3718b8058d5b90a533160ff37b611a ed-1.19-rc1.tar.lz Please, test it and report any bugs you find. GNU ed is a line-oriented text editor.

Re: While we're talking about new features

2022-11-19 Thread Antonio Diaz Diaz
Shawn Wagner wrote: Two more I have in mind: Supporting a GNU sed extension of taking both a starting offset and g with s///Ng - replace all matches starting with the Nth one. I have this mostly done; I'm not sure how it should interact with the current toggling behavior of sN and sg, though.

Re: eE-command bug

2022-10-20 Thread Antonio Diaz Diaz
Dear Harry, Harry Graf wrote: If you have an unmodified buffer and you read a file with e or E command, which does not exist, the modified flag get set by the delete_lines function, which sets the mofified_ flag to true. This prevents a new trail e/E command with an error message "modified". T

Re: red: simplify wrapper script

2022-06-22 Thread Antonio Diaz Diaz
Hi Akbar, Akbarkhon Variskhanov wrote: Hi. The wrapper script for 'red' is unnecessarily complicated. Here is a simplified version of it. Thanks, but it seems that your simplified 'red' fails when $0 does not contain a slash: $ sh red.orig -V GNU ed 1.18 [...] $ sh red.new -V red.new: line

Re: Questions about COPYING

2022-02-09 Thread Antonio Diaz Diaz
Hi Wangmy, wan...@fujitsu.com wrote: I upgraded ed to 1.18 and found that in the COPYING, the license changed from GPLv3 to GPLv2. But I haven't found the reason for this change. Can you provide this information to me? Sure. As you can see in line 190 of the ChangeLog, in version 1.5 I mista

GNU ed 1.18 released

2022-02-07 Thread Antonio Diaz Diaz
I am pleased to announce the release of GNU ed 1.18. GNU ed is a line-oriented text editor. It is used to create, display, modify and otherwise manipulate text files, both interactively and via shell scripts. A restricted version of ed, red, can only edit files in the current directory and can

Re: Escaped percent sign in shell escape (bang) command (ed 1.16)

2022-01-12 Thread Antonio Diaz Diaz
Andrew L. Moore wrote: There are a couple of issues that I'd encourage you to explore: Thank you. Your suggestions are very welcome. :-) 1) Though POSIX doesn't specify ed's behavior when commands are read from a pipe, historically, errors do not cause ed to exit. Nonetheless, errors should b

Re: Escaped percent sign in shell escape (bang) command (ed 1.16)

2022-01-08 Thread Antonio Diaz Diaz
Hello Andrew, Andrew L. Moore wrote: | Martin Thomsen wrote: | printf '%s\n' 'r !date +"% modified on \%F"' ',p' Q | ed -s fil1 | | outputs | | date +"fil1 modified on \%F" | fil1 modified on \2021-07-10 | | I think the output should contain no backslashes, per POSIX | documentation. The GNU ed

[Bug-ed] GNU ed 1.18-rc1 released

2022-01-03 Thread Antonio Diaz Diaz
GNU ed 1.18-rc1 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.18-rc1.tar.lz The sha256sum is: 8384295126caf09c2ec3e87a3d3de675d06b25fe6bb117618f7b0aeb14d1d09c ed-1.18-rc1.tar.lz Please, test it and report any bugs you find. GNU ed is a line-oriented text editor.

Re: Buffered I/O and ed shell escape command

2021-12-29 Thread Antonio Diaz Diaz
Hi Sören, Sören Tempel wrote: I did some experiments with the shell escape command today and noticed that the command behavior depends on the output stream on my system: Thank you very much for reporting this. I have fixed it by flushing stdout as in the patch below. I'll soon release a new v

[Bug-ed] GNU ed 1.18-pre3 released

2021-10-13 Thread Antonio Diaz Diaz
GNU ed 1.18-pre3 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.18-pre3.tar.lz The sha256sum is: 8d00b510d3f533c7e9dff9af689834af4e360bb53ad32d43e6d6c5a5e9f54659 ed-1.18-pre3.tar.lz Please, test it and report any bugs you find. GNU ed is a line-oriented text edito

Re: [PATCH] ed with perl-compatible regular expressions

2021-07-29 Thread Antonio Diaz Diaz
Shawn Wagner wrote: I'm mostly trying to fix one annoyance I've found - simple to use case-insensitive regular expressions. Having more powerful REs available as an option and parity with the flavors of RE accepted by its stepchild grep are just added bonuses. If you don't want to use this one, w

Re: [PATCH] ed with perl-compatible regular expressions

2021-07-26 Thread Antonio Diaz Diaz
Dear Shawn, Shawn Wagner wrote: The attached patch (Made against 1.18-pre2) adds a -P option to use PCRE2 regular expressions. Passing --disable-pcre2 to the configure script will leave this feature out. There's also a --utf8 option that turns on PCRE2's advanced Unicode matching. Thank you fo

[Bug-ed] GNU ed 1.18-pre2 released

2021-07-19 Thread Antonio Diaz Diaz
GNU ed 1.18-pre2 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.18-pre2.tar.lz The sha256sum is: 96176dc16c63449c736ecd9ae86821bd2efb6c07d9e706fca58c9972b40c2a40 ed-1.18-pre2.tar.lz Please, test it and report any bugs you find. GNU ed is a line-oriented text edito

Re: Escaped percent sign in shell escape (bang) command (ed 1.16)

2021-07-14 Thread Antonio Diaz Diaz
John Cowan wrote: The Posix standard says "Within the text of that shell command line, the unescaped character '%' shall be replaced with the remembered pathname". Which is what GNU ed does. Now if "unescaped" means anything at all here, it means "not preceded by a backslash", just like every

Re: Escaped percent sign in shell escape (bang) command (ed 1.16)

2021-07-13 Thread Antonio Diaz Diaz
Hello, Martin Thomsen wrote: Using GNU bash 5.0.17(1) and GNU ed version 1.16 the command printf '%s\n' 'r !date +"% modified on \%F"' ',p' Q | ed -s fil1 outputs date +"fil1 modified on \%F" fil1 modified on \2021-07-10 I think the output should contain no backslashes, per POSIX documentati

Re: ed documentation feedback: accessibility, clarity, and a typing mistake

2021-04-23 Thread Antonio Diaz Diaz
Dear David, Thank you again. I have fixed all the issues you reported. The corrected home page and manual are already online. Best regards, Antonio.

[Bug-ed] GNU ed 1.18-pre1 released

2021-03-21 Thread Antonio Diaz Diaz
GNU ed 1.18-pre1 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.18-pre1.tar.lz The sha256sum is: 7bc4b0c910e9f807356d5fe5cf2e2ead433c2adf3360a5baf6343d0d6d33d8c7 ed-1.18-pre1.tar.lz Please, test it and report any bugs you find. GNU ed is a line-oriented text edito

Re: [bug-ed] BUGs: static code analysis (gcc, clang, cppcheck)

2021-03-10 Thread Antonio Diaz Diaz
Hola Xose, Thanks for your report. Xose Vazquez Perez wrote: signal.c: In function 'sighup_handler.part.0': signal.c:57:9: warning: leak of '' [CWE-401] [-Wanalyzer-malloc-leak] 57 | if( len && hup ) /* hup filename */ | ^ The code in question is this: if( len && hup )

GNU ed 1.17 released

2021-01-13 Thread Antonio Diaz Diaz
I am pleased to announce the release of GNU ed 1.17. GNU ed is a line-oriented text editor. It is used to create, display, modify and otherwise manipulate text files, both interactively and via shell scripts. A restricted version of ed, red, can only edit files in the current directory and can

Re: Errors in man pages

2020-12-21 Thread Antonio Diaz Diaz
Dear Dr. Kreutzmann, Helge Kreutzmann wrote: Secondly we translators see the manpages in the neutral po format, i.e. converted and harmonized, but not the original source (be it man, groff, xml or other). So we cannot provide a true patch (where possible), but only an approximation which you nee

Re: [bug-ed] Suggestions

2020-11-28 Thread Antonio Diaz Diaz
Dear Issam, Issam E. Maghni wrote: I am not asking about replacing lzip, but simply to add gzip. In practice, people tend to use their format of choice (xz, bzip2 or lzip) in addition to gzip for tarball distribution. Gzip is universally accepted and widely used. You can use pigz and libzopfli t

[Bug-ed] GNU ed 1.17-rc1 released

2020-11-28 Thread Antonio Diaz Diaz
GNU ed 1.17-rc1 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.17-rc1.tar.lz The sha256sum is: 6616cceda3eb128dd6fb947f4791a06bcc5d70e67c921739ada707d066e8ce21 ed-1.17-rc1.tar.lz Please, test it and report any bugs you find. GNU ed is a line-oriented text editor.

Re: ed.texi to PDF

2020-11-28 Thread Antonio Diaz Diaz
Matt Wette wrote: I ran texi2any --pdf ed.texi and it failed. This is on ed-1.16. The following makes it work. Thanks for reporting this. I have verified that ed.texi since ed 0.3 seems to be implemented as documented in the texinfo manual[1]. Therefore this seems a bug either in texi2any or

Re: [bug-ed] Suggestions

2020-11-27 Thread Antonio Diaz Diaz
ting systems (for example used to build Docker images). After consulting Antonio Diaz Diaz (creator of Lzip), he kindly added the necessary functionality to Lzip and Lzip can now be built without Make. Hence we don't need this assumption any more. With this commit, Lzip and GNU Make ar

Re: [bug-ed] Is a directory

2020-11-16 Thread Antonio Diaz Diaz
Hi Dan, Dan Jacobson wrote: $ ed /cf/updates/couchsurfing/*ref* Is a directory #OK, but say what. Thanks for reporting this. I have already located the problem and will fix it as soon as possible. Best regards, Antonio.

Re: Git?

2020-09-25 Thread Antonio Diaz Diaz
Hi Faissal, Faissal Isslam Bensefia wrote: Hi, I'm looking into making some modifications to The Standard Editor and was just curious if there was a plan to move to Git at some point? There are no plans to move to git, but if you plan to share your modifications, a patch against the latest ve

Re: 1.14.1.tar.lz is missing

2020-08-19 Thread Antonio Diaz Diaz
Hello Efraim, Efraim Flashner wrote: I'm working to see if it's possible to revive the mips64el-linux port in GNU Guix and as part of the process I needed the 1.14.1 tarball to satisfy the dependency graph. Unfortunately it seems to be missing from the ftp site (https://ftp.gnu.org/pub/gnu/ed/).

[Bug-ed] GNU ed 1.17-pre2 released

2020-08-06 Thread Antonio Diaz Diaz
GNU ed 1.17-pre2 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.17-pre2.tar.lz The sha256sum is: b7c44f5a7f31245ff5a2259acb3029483b7fc2c001e2e89de5a7b819b98edde5 ed-1.17-pre2.tar.lz Please, test it and report any bugs you find. GNU ed is a line-oriented text edito

Re: [PATCH] Support POSIX extended regular expressions

2020-07-20 Thread Antonio Diaz Diaz
Dear Shawn, Shawn Wagner wrote: - n = regcomp( exp, pat, 0 ); + n = regcomp( exp, pat, use_extended_re ? REG_EXTENDED : 0 ); Thank you for the patch. POSIX states[1] that "The ed utility shall support basic regular expressions, as described in XBD Basic Regular Expressions", but yours look

[Bug-ed] GNU ed 1.17-pre1 released

2020-05-06 Thread Antonio Diaz Diaz
GNU ed 1.17-pre1 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.17-pre1.tar.lz The sha256sum is: 332bb859c77146ee81c03bbeb2d6b3ab64062423cc53a40bafa991b53e41f9b0 ed-1.17-pre1.tar.lz Please, test it and report any bugs you find. GNU ed is a line-oriented text edito

Re: Quit in global command

2020-04-02 Thread Antonio Diaz Diaz
Dear Dr. Harris, arc...@azalea.name wrote: It appears there is a bug either in the documentation or the functionality. Trying to do a quit (q/Q) in a global (g/v) command fails, contrary to this "Any commands are allowed, except for 'g', 'G', 'v', and 'V'." Thank you for reporting this. The

GNU ed 1.16 released

2020-02-22 Thread Antonio Diaz Diaz
I am pleased to announce the release of GNU ed 1.16. GNU ed is a line-oriented text editor. It is used to create, display, modify and otherwise manipulate text files, both interactively and via shell scripts. A restricted version of ed, red, can only edit files in the current directory and can

Re: [Bug-ed] Error in POSIX ed address?

2020-01-16 Thread Antonio Diaz Diaz
Antonio Diaz Diaz wrote: Bob Proulx wrote: Therefore the Addr2 column for 7,+ should say ".+1". Saying 8 there is definitely not correct. Thanks. I'll report it to the Austin group when I find the time. I'll use your message as reference. This has been fixed

Re: [bug-ed] Cut buffer does not persist between files

2020-01-13 Thread Antonio Diaz Diaz
Hi Bob, Bob Proulx wrote: And so if you asked me what the 'x' command did I would have said it did encryption! Interesting. I didn't know. So maybe this new fangled 'y' command and different 'x' command instead of encryption will catch on. Maybe not. Who is to say? It is only been in GNU

[Bug-ed] GNU ed 1.16-rc1 released

2019-12-21 Thread Antonio Diaz Diaz
GNU ed 1.16-rc1 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.16-rc1.tar.lz The sha256sum is: 181497ff31d39a6ecce57e203ace7868e85f83ab801f78151097215de4108ca8 ed-1.16-rc1.tar.lz Please, test it and report any bugs you find. This is planned to be the only release

Re: [bug-ed] Cut buffer does not persist between files

2019-12-04 Thread Antonio Diaz Diaz
Brian Zwahr wrote: I'm running into an issue that I'm not sure if it's a feature, a bug, or just an oversight. If I open a file in ed, yank some text with `y`, then open a new file for editing using `e`, I can't paste the yanked text with `x`. This has been GNU ed's behavior since the yank buff

[Bug-ed] GNU ed 1.16-pre2 released

2019-04-24 Thread Antonio Diaz Diaz
GNU ed 1.16-pre2 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.16-pre2.tar.lz The sha256sum is: 56b814f6881d359e42c201124904a52b3d47598402a5671e4a457fdc573183ab ed-1.16-pre2.tar.lz Please, test it and report any bugs you find. GNU ed is an 8-bit clean, more or le

Re: [Bug-ed] [Patch] Remove arbitrary 80-character prompt limitation

2019-04-15 Thread Antonio Diaz Diaz
Hello Tim, Thanks for reporting this. I'll release a fixed version as soon as possible. Best regards, Antonio. ___ bug-ed mailing list bug-ed@gnu.org https://lists.gnu.org/mailman/listinfo/bug-ed

Re: [Bug-ed] Improve doc

2019-04-01 Thread Antonio Diaz Diaz
Hello Nich, Thanks for your message. I'll try to clarify in ed's documentation all the points you raise. Meanwhile, you can find some updated information in the latest manual for GNU ed (1.15)[1], and in the POSIX documentation for ed[2]. [1] http://www.gnu.org/software/ed/manual/ed_manual.h

[Bug-ed] GNU ed 1.16-pre1 released

2019-03-05 Thread Antonio Diaz Diaz
GNU ed 1.16-pre1 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.16-pre1.tar.lz The sha256sum is: f8b7d77b0dd30c2623226584ac332afd3057c3b0c614b279fc2857b26630d9b5 ed-1.16-pre1.tar.lz Please, test it and report any bugs you find. GNU ed is an 8-bit clean, more or le

Re: [Bug-ed] Different behavior GNU ed and oed

2019-03-01 Thread Antonio Diaz Diaz
Hi Bjoern, Bjoern Wibben wrote: :g/test/s/^/#/g infinite substitution loop Thanks for reporting this. GNU ed has always behaved like this for non-empty replacements of empty matches, but it could be more clever and notice that /^/ can only match once in a line and ignore the 'g' suffix. I

Re: [Bug-ed] 2 typos in ed documentation

2019-01-25 Thread Antonio Diaz Diaz
Hello, Rusty Shackleford wrote: From 'info Ed', section 'Commands', detailing '(.,.)s': "The 'r' suffix causes the regular expression of the last search to be used instead of *the that* of the last substitution." Same section, detailing '(1,$)w FILE': "Any previous contents of FILE *is* lost w

Re: [Bug-ed] Searching for multiple matches with \+ isn't working

2019-01-04 Thread Antonio Diaz Diaz
Brian Zwahr wrote: One thing still isn't clear to me, and that's the archives. Bob says he can see this conversation in the archives and that they update every 30 minutes like they say they do. However, I don't see anything in the archives past last October. Here's a screenshot of what I see. Wha

Re: [Bug-ed] Searching for multiple matches with \+ isn't working

2019-01-03 Thread Antonio Diaz Diaz
Hi Bob, Bob Proulx wrote: P.S. Antonio, I twiddled the mailing list settings somewhat in response to this. Please, tell me that you configured it to remove the html part from emails. That would be wonderful. :-) Thanks, Antonio. ___ bug-ed maili

Re: [Bug-ed] Searching for multiple matches with \+ isn't working

2019-01-03 Thread Antonio Diaz Diaz
Brian Zwahr wrote: So 1.15 is officially released? Sorry for not being more clear. Y released ed 1.15 two days ago, but I have just announced it now to allow wordwide mirrors time to copy it. Unrelated side note: the mailing list rules state that only text emails (no HTML) should be used, so

[Bug-ed] GNU ed 1.15 released

2019-01-03 Thread Antonio Diaz Diaz
I am pleased to announce the release of GNU ed 1.15. GNU ed is a line-oriented text editor. It is used to create, display, modify and otherwise manipulate text files, both interactively and via shell scripts. A restricted version of ed, red, can only edit files in the current directory and can

Re: [Bug-ed] Searching for multiple matches with \+ isn't working

2019-01-02 Thread Antonio Diaz Diaz
Brian Zwahr wrote: Either way, though, shouldn't the GNU ed manual (I linked it in a previous message) mention needing extensions or a specific regular expressions implementation in order for all operators, like \+, to work? The BSD ed man page mentions it, as you've pointed out. The GNU ed docum

Re: [Bug-ed] GNU ed 1.15-pre2 released

2018-10-28 Thread Antonio Diaz Diaz
Hi Bob, Bob Proulx wrote: Are you interested in reports of spurious gcc warnings? It isn't an ed bug but rather a gcc bug. Using gcc 6.3.0 and gcc 8.2.0 are both opinionated about whitespace and indention and noisy compiling the main_loop.c file. gcc -Wall -W -O2 -c -o main_loop.o main_loop.

[Bug-ed] GNU ed 1.15-pre2 released

2018-10-25 Thread Antonio Diaz Diaz
GNU ed 1.15-pre2 is ready for testing here http://download.savannah.gnu.org/releases/ed/ed-1.15-pre2.tar.lz The sha256sum is: 01c43b16456b214da1d6862e3aa13a4831d5ad6ed5b77d58bbec8e81c4fc5598 ed-1.15-pre2.tar.lz Please, test it and report any bugs you find. GNU ed is an 8-bit clean, more or le

Re: [Bug-ed] Error in POSIX ed address?

2018-10-20 Thread Antonio Diaz Diaz
Hi Bob, Bob Proulx wrote: Not seeing anyone else respond I thought I would make a comment. Thank you for your very informative comment. Therefore the Addr2 column for 7,+ should say ".+1". Saying 8 there is definitely not correct. Thanks. I'll report it to the Austin group when I find th

[Bug-ed] Error in POSIX ed address?

2018-10-17 Thread Antonio Diaz Diaz
Hello all. I was fixing the ',,' address bug reported by Matthieu Felix when I found what I think is an error in the POSIX page for ed: http://pubs.opengroup.org/onlinepubs/9699919799/utilities/ed.html Address Addr1 Addr2 7,+ 7 8 7;+ 7 8 The first row should be equiva

Re: [Bug-ed] Global substitutions that insert newlines

2018-10-17 Thread Antonio Diaz Diaz
Rob Arthan wrote: This is an annoying side-effect of the POSIX standardisation: some implementations of ed allowed the terminating character to be dropped from a substitution command (i.e., they allowed "s//" as well as "s///"). This introduced an "ambiguity" (in the POSIX description and not, a

Re: [Bug-ed] Global substitutions that insert newlines

2018-10-15 Thread Antonio Diaz Diaz
Hello Rob, Rob Arthan wrote: I have a script that uses ed to generate C string definitions from nroff output. It makes essential use of global substitutions with a newline as the replacement text, e.g., g/^##*/s/#*/\ / This functionality is no longer available as of version 1.14 of GNU ed. Is

Re: [Bug-ed] Problems in POSIX description of ed have been resolved

2018-09-16 Thread Antonio Diaz Diaz
Ori Avtalion wrote: Thanks, Antonio. You are welcome. I have also file an issue about the "s/RE" command: http://austingroupbugs.net/view.php?id=1204 Thanks. I have just started monitoring it. ___ bug-ed mailing list bug-ed@gnu.org https://lists

[Bug-ed] Problems in POSIX description of ed have been resolved

2018-09-16 Thread Antonio Diaz Diaz
Hello all (specially Ori Avtalion), In March 2107 I reported to the Austin group a couple problems with the 'c' and 'i' commands. Both of them have been fixed. See the details in the following links: http://austingroupbugs.net/view.php?id=1130 http://austingroupbugs.net/view.php?id=1131 Summa

Re: [Bug-ed] Ed scripts failing in versions after ~1.10

2018-05-22 Thread Antonio Diaz Diaz
David Given wrote: Adding -l does produce an exit status of 0 --- but will this still cause genuine failures if, for example, there's a syntax error in the script? Sadly the current implementation of '-l' is pretty simple. It will ignore about any error: $ ed -v ; echo $? b ? Unknown command

Re: [Bug-ed] Ed scripts failing in versions after ~1.10

2018-05-22 Thread Antonio Diaz Diaz
Ori Avtalion wrote: When the Q command is issued on a modified buffer, I don't understand why ed exits with exit status 1 instead of 0. No error has occurred. The Q command does not cause ed to exit with status 1: $ ed -v ; echo $? 0a foo . Q 0 But it does not prevent an exit status of 1 if s

  1   2   3   >