4 ms·
> [BSD sed] you can also do sed -i -e 's/a/b/' file which will work for GNU and BSD sed.
by ibotty 8y ago
> [BSD sed]
you can also do
sed -i -e 's/a/b/' file
which will work for GNU and BSD sed.
- bonzini 8y agoNo, it doesn't. On BSD sed it will produce a backup file named file-e. The portable way is to use-i.bak and then get rid of the backup file.