dwmkerr / dwmkerr/effective-shell

Issues in Chapter 4: Regular Expressions Essentials

Open
#382 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
780
Forks
93
Avg merge
1d 7h
Merged PRs (30d)
3

Description

There are a couple of issues in Chapter 4 of the No Starch Press book.

1. There is a missing/extra line in sample set of email addresses.
On page 49
Listing 4-1 is as follows:

> $ cat ~/effective-shell/data/email-addresses.txt
dave@effective-shell.com
dave@effective-shell
to: dave@effective-shell.com
dave@effective-shell.com
test123.effective-shell.com
@yahoo.com
whatever123@😂.com
dave@kerr@effective.shell.com

however, on page 51-52 we see an additional line, "dave@":

> dave@effective-shell.com
dave@effective-shell
to: dave@effective-shell.com
dave@effective-shell.com
test123.effective-shell.com
@yahoo.com
dave@
whatever123@😂.com
dave@kerr@effective.shell.com

2. In the "Adding Special Characters" section starting on page 53, the first sentence reads as follows:

> To include more characters in the match, you can add them directly to your
character set—for example, the following pattern adds the +.

however, the pattern shown is:

> [\w\-.]+@[\w\-.]+

which adds the "-" and ".", but not the "+".

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.