Question: I have a file containing a huge (3400+ lines) list of URLs, each of which looks something like this:

```
http://examplesite/rn/index.php?PageID=SF01_02_01&ID=2015-12-23-0012

```

What I would like to do is use `sed` to select all lines containing today's date.

What I've been trying is:

```
datetoday=$(date +%Y-%m-%d)
sed "/$datetoday/!d" en.html

```

However, this seems to blank the file suggesting that no lines match the string. Any suggestions?

Answer: 
You can use flag `p` instead `d`:

`sed -n "/$(date +%Y-%m-%d)/p" en.html`
You could use GNU awk instead of 2 separate commands:

```
awk '$0~strftime("%F")'

```