2

Since Ex is a standard Unix editor (standardized by POSIX), I expect to be shipped with OS X, however it's linked into vim instead as shown below:

$ stat /usr/bin/ex
  File: ‘/usr/bin/ex’ -> ‘vim’

My goal is to test some syntax within Ex it-self (not using extended vim-like ex syntax) in order to check if my command is POSIX-compliant.

Therefore where I can find the original Ex editor on OS X? Or if it was removed or not shipped with, how can I get it back?

  • I believe vim has a mode which it claims to be a standard-compliant implementation of ex. Note that for any other package you install, you only have the author's word that it is standards compliant. – IMSoP Jan 7 '16 at 16:26
4

You could install it using Homebrew. It is part of the brew ex-vi package, e.g.:

brew install ex-vi

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .