GNU bug report logs - #28881
sed guide mistake

Previous Next

Package: sed;

Reported by: Nick Chambers <dtscode <at> gmail.com>

Date: Tue, 17 Oct 2017 21:20:02 UTC

Severity: normal

Done: Assaf Gordon <assafgordon <at> gmail.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 28881 in the body.
You can then email your comments to 28881 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-sed <at> gnu.org:
bug#28881; Package sed. (Tue, 17 Oct 2017 21:20:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Nick Chambers <dtscode <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-sed <at> gnu.org. (Tue, 17 Oct 2017 21:20:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Nick Chambers <dtscode <at> gmail.com>
To: bug-sed <at> gnu.org
Subject: sed guide mistake
Date: Tue, 17 Oct 2017 14:52:06 -0500
Hello! In the GNU guide for SED:
https://www.gnu.org/software/sed/manual/sed.html#Introduction, I see
the following:

sed -i 's/hello/world' file.txt

However on my ubuntu machine I get the following:

nchambers <at> dev-server:~$ sed --version
sed (GNU sed) 4.4
Copyright (C) 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by Jay Fenlason, Tom Lord, Ken Pizzini,
and Paolo Bonzini.
GNU sed home page: <http://www.gnu.org/software/sed/>.
General help using GNU software: <http://www.gnu.org/gethelp/>.
E-mail bug reports to: <bug-sed <at> gnu.org>.
nchambers <at> dev-server:~$ cat file.txt
hello world
this is a message
good day!
nchambers <at> dev-server:~$ sed -i 's/hello/world' file.txt
sed: -e expression #1, char 13: unterminated `s' command
nchambers <at> dev-server:~$


it works fine if I do

sed -i 's/hello/world/' file.txt

Thanks all!




Information forwarded to bug-sed <at> gnu.org:
bug#28881; Package sed. (Tue, 17 Oct 2017 22:52:02 GMT) Full text and rfc822 format available.

Message #8 received at 28881 <at> debbugs.gnu.org (full text, mbox):

From: Assaf Gordon <assafgordon <at> gmail.com>
To: Nick Chambers <dtscode <at> gmail.com>, 28881 <at> debbugs.gnu.org
Subject: Re: bug#28881: sed guide mistake
Date: Tue, 17 Oct 2017 16:50:55 -0600
[Message part 1 (text/plain, inline)]
Hello,

On 2017-10-17 01:52 PM, Nick Chambers wrote:
> Hello! In the GNU guide for SED:
> https://www.gnu.org/software/sed/manual/sed.html#Introduction, I see
> the following:
> 
> sed -i 's/hello/world' file.txt

Thank you for the bug report.

Attached is a fix.
I will soon push it if there are no further comments.

regards,
 - assaf

[0001-doc-fix-missing-slash-in-example.patch (text/x-patch, attachment)]

Information forwarded to bug-sed <at> gnu.org:
bug#28881; Package sed. (Tue, 17 Oct 2017 23:50:02 GMT) Full text and rfc822 format available.

Message #11 received at 28881 <at> debbugs.gnu.org (full text, mbox):

From: Jim Meyering <jim <at> meyering.net>
To: Assaf Gordon <assafgordon <at> gmail.com>
Cc: 28881 <at> debbugs.gnu.org, Nick Chambers <dtscode <at> gmail.com>
Subject: Re: bug#28881: sed guide mistake
Date: Tue, 17 Oct 2017 16:48:39 -0700
On Tue, Oct 17, 2017 at 3:50 PM, Assaf Gordon <assafgordon <at> gmail.com> wrote:
> On 2017-10-17 01:52 PM, Nick Chambers wrote:
>>
>> Hello! In the GNU guide for SED:
>> https://www.gnu.org/software/sed/manual/sed.html#Introduction, I see
>> the following:
>>
>> sed -i 's/hello/world' file.txt
>
>
> Thank you for the bug report.
>
> Attached is a fix.
> I will soon push it if there are no further comments.

Clearly necessary and correct. Thank you both.




Reply sent to Assaf Gordon <assafgordon <at> gmail.com>:
You have taken responsibility. (Wed, 18 Oct 2017 00:54:02 GMT) Full text and rfc822 format available.

Notification sent to Nick Chambers <dtscode <at> gmail.com>:
bug acknowledged by developer. (Wed, 18 Oct 2017 00:54:02 GMT) Full text and rfc822 format available.

Message #16 received at 28881-done <at> debbugs.gnu.org (full text, mbox):

From: Assaf Gordon <assafgordon <at> gmail.com>
To: Jim Meyering <jim <at> meyering.net>
Cc: 28881-done <at> debbugs.gnu.org, Nick Chambers <dtscode <at> gmail.com>
Subject: Re: bug#28881: sed guide mistake
Date: Tue, 17 Oct 2017 18:53:16 -0600
On 2017-10-17 05:48 PM, Jim Meyering wrote:
> On Tue, Oct 17, 2017 at 3:50 PM, Assaf Gordon <assafgordon <at> gmail.com> wrote:
>> On 2017-10-17 01:52 PM, Nick Chambers wrote:
>>>
>>> sed -i 's/hello/world' file.txt
>>
>> Attached is a fix.
> 
> Clearly necessary and correct. Thank you both.

Thanks, pushed here:
 https://git.savannah.gnu.org/cgit/sed.git/commit/?id=9f99a4f51





bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 15 Nov 2017 12:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 7 years and 274 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.