ForNeVeR / ExtDiff

Compare documents using MS Word from the command line.
MIT License
123 stars 18 forks source link

equivalent functionality in Mac OS? #4

Closed ghost closed 6 years ago

ghost commented 6 years ago

Would you know if Diff-Word.ps1 can be modified to allow for this to work in Mac OS?

ForNeVeR commented 6 years ago

Hello. This script uses official COM API of Microsoft Word for Windows. COM is definitely not a way of doing things on macOS, although you have a couple of options (I am not a macOS expert so take my advice with a grain of salt):

  1. There's some thing called Automator that seems to be applicable to automate GUI things on macOS, see here for details.
  2. Some guys here have generated an Word API header file and written an ObjC program that manipulates Word. The API looks similar to the COM API used in ExtDiff. Probably you could take a look there.

Unfortunately, my area of expertise is PowerShell scripting and not macOS programming, so I don't think I can help you more that that.

Soneji commented 5 years ago

Is this possible now that powershell has been open sourced and there are now mac binaries?

ForNeVeR commented 5 years ago

What this project uses is COM API provided by the Microsoft Office on Windows. If it provides any kind of automation API on macOS, then it's possible even without involvement of PowerShell (I would personally prefer to see something that executes natively without additional dependencies on macOS, e.g bash).