Closed seanjensengrey closed 8 years ago
gsed isn't a standard alias; and I'd like to keep the lua makefile changes to a minimum.
Is there an easy way to prepend to a file without use of sed?
Or a change to my sed
invocation that will make it work with either gnu sed or bsd sed?
Understandable. I played with bsd sed vs gnu sed for awhile, I am no sedspert, and couldn't find an intersection of features. What about a python2 one liner ?
It does only attempt to use gsed while on Darwin and the comments direct one to install gnu-sed
via Homebrew. I don't know what macports calls sed on OSX.
What about a python2 one liner ?
No python. Could probably use awk
. Or could just fall back to echo
+ cat
and shell redirection.
I removed the call to sed
completely. Tested with my application using a built version of lua.vm.js
using
emcc (Emscripten gcc/clang-like replacement) 1.36.5 (commit 8e29cf1b1d39f5d86aaeb702597aa34d97cd763a)
I built but did no test on Ubuntu 14.04 using emcc 1.10.0
Merged :)
This fixes an issue I was seeing between BSD sed and Gnu sed