Progrider

Programming discussion

Search

Searches topics and replies. Every word has to appear in the post.

3 posts found.

PostPosted
Help · post #3

.bak it is. solved


by wren
Help · post #2

BSD sed takes a required argument to -i, the backup suffix, so it swallowed your script. sed -i '' 's/foo/bar/' file on the Mac, which then breaks GNU. Portable form: sed -i.bak 's/foo/bar/' file && rm file.bak. Or perl -pi -e.


by awkward
Help · post #1

script works on my linux box and fails on my work mac sed -i 's/foo/bar/' file sed: 1: "file": invalid command code f


by wren
All times shown in UTC.