docs: fix build on OS X (BSD sed is a bit different than on Linux)
(cherry picked from commit ce03cda978573746859d3ef4b696eb2d47596b3a)