Various Bash guides recommend putting quotes around just about everything.
I had a script that contained this line:
sudo apt-get install --yes $(cat "$BUILD/install_on_aws_ubuntu.txt")
While refactoring, I put another set of quotes around the $(cat ...)
out of an abundance of caution:
sudo apt-get install --yes "$(cat "$BUILD/install_on_aws_ubuntu.txt")"
Several other changes later, I couldn’t figure out why my script had stopped working.
Here’s what happened:
$ cat $HOME/tmp/demo.txt
$ echo $(cat "$HOME/tmp/demo.txt")
foo bar quux
$ echo "$(cat $HOME/tmp/demo.txt)"
The new outer quotes retained the newlines;
the original replaced newlines with spaces.
The Bash FAQ has more: specifically Command Substition and Word Splitting.
Title: The Fourth Secret
Author: Andrea Camilleri
Rating: ★ ★ ★
Reading period: February 28–March 2, 2016
A quirky novella about Commissario Montalbano of the Italian Polizia.
A series of “accidents” have been happening at construction sites.
Montalbano receives an anonymous letter warning that another “accident” will happen,
too late to prevent it.
He attempts to cover it up, while still investigating,
and realizes that he’s infringing on the caribinieri‘s jurisdiction, a no-no.
My birthday today marks the 25th anniversary of my coming out as bisexual,
a major milestone in my life.
I hid my bisexuality for a decade before coming out in 1991.
Ireland was not a welcoming place for LGBT youth in the 1980s.
Nor were most other places.
I discovered soc.motss, the gay newsgroup on Usenet,
in the late 1980s
and I lurked there for a couple of years,
half-intending to come out but never quite finding the courage.
Then my old friend Éamonn came out to me—to my utter surprise—and I immediately came out to him.
Then I sat on everything for a few months.
Eventually, late on the night of my …continue.
3/14 is considered to be Pi Day by many geeks, as π is approximately 3.14.
I wish I could say that I had celebrated by eating pie,
but I didn’t.
π is surely the most important irrational number,
which has been known since antiquity.
π shows up in so many different formulas.
My own favorite is Euler’s Identity,
eiπ + 1 = 0.
(This marks the first use of the reStructuredText math role in my blog.)
I am also find of the approximate fraction 355 ⁄ 113.
The Wikipedia article on π has much more on π.
Wonkblog: 10 stunning images show the beauty hidden in pi
Author: Anthony Horowitz
Rating: ★ ★ ★ ½
Reading period: 27 February–5 March, 2016
Pinkerton agent Frederick Chase arrives at Reichenbach Falls
just after Sherlock Holmes and Professor Moriarty have plunged to their deaths.
With Inspector Athelney Jones of Scotland Yard—surely one of Holmes’s most ardent students—he travels to London on the trail of an American master criminal, Clarence Devereaux.
Devereaux’s gang is moving quickly and ruthlessly
to seize control of the vacuum left by Moriarty.
But not all is it appears and the American gang receive bloody setbacks.
Could Moriarty be alive after all?
While I mostly enjoyed the book, I was exasperated by …continue.
Daylight Saving Time is hot garbage
is a typical article you can expect to read this weekend
My own dislike of DST was boosted when I worked on calendar software at Cozi.
We learned the hard way that we needed to test our latest software
ahead of both the start and end of DST each year.
That’s trickier than you might think.
Setting the computer’s clock forward a couple of weeks,
past the change of DST, is one thing;
getting the changed time to last for more than a few minutes is another.
Most computers aggressively sync their clocks to a network time server,
which can be tricky to disable.
I no …continue.
In an interview with MSNBC Friday,
2016 Democratic presidential candidate Hillary Clinton said
that Ronald and Nancy Reagan helped start a national conversation about HIV/AIDS.
This is not exactly a bald-faced lie,
but it is a gross misunderstanding of history
and a misrepresentation of the true governmental neglect
during the AIDS epidemic that killed millions worldwide.
—Mathew Rodriguez, mic.com
As I wrote on Facebook earlier today:
I’m really surprised by this.
I expected Hillary Clinton to know better.
It’s one thing not to speak ill of the dead at their funeral.
It’s quite another to make such a profoundly wrong assertion.
The Reagan White House’s negligence and homophobia
was directly responsible for the growth of the …continue.
Title: Mother London
Author: Michael Moorcock
Rating: ★ ★ ★
Reading period: 22 February–10 March, 2016
Mother London is well written and it has some fine scenes and three interesting characters.
I wanted to like it but it never engaged me
because the story goes nowhere.
I rarely abandon books, but I gave up on this two-thirds of the way through.
Mother London follows three outpatients from a mental hospital,
between 1940 and the 1980s:
Josef Kiss, a larger-than-life performer,
David Mummery, a writer,
and Mary Gasalee, a housewife who spends fifteen years in a coma, after the Blitz.
All three seem to be psychically sensitive to the thoughts …continue.
It is often said that people fear public speaking more than they fear death.
I certainly used to fear getting up in front of a crowd,
though not to the point of death.
Tonight I spoke about FlyingCloud
in front of more than 100 people for half an hour
at the PuPPy Meetup.
I wasn’t nervous beforehand and I wasn’t nervous talking to the crowd.
I’ve been an active Toastmaster for nearly 15 years
and I’ve spoken at Toastmasters hundreds of times.
I’m used to a room of 15–25 people but not to a larger audience.
Adam and I put our slides together late last week.
We ran through it together once …continue.
Boing Boing posted Irish slave myths debunked,
a link to the work of Liam Hogan.
The indentured servitude that brought many Irish people to the Americas
could be very harsh, but it wasn’t slavery.
Slavery was brutal and often murderous,
the children of slaves were themselves slaves,
and the aftermath continues to affect their descendants even now.