The last sed has an unescaped single quote.
You should replace this:
That's a single quote surrounded by double quotes. Backslash won't work.
You'll find some explanations here:
CONFIDENTIALITY NOTICE: This message is the property of International Game
Technology PLC and/or
its subsidiaries and may contain proprietary, confidential or trade secret
This message is intended solely for the use of the addressee. If you are not
the intended recipient
and have received this message in error, please delete this message from your
system. Any unauthorized
reading, distribution, copying, or other use of this message or its attachments
is strictly prohibited.
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
To post to this group, send email to email@example.com.
To view this discussion on the web visit
For more options, visit https://groups.google.com/d/optout.