miraisolutions / compareWith

RStudio Addins for Enhanced Diff and Merge
55 stars 11 forks source link

Fix repo comparison on Windows, switch to package sys #27

Closed riccardoporreca closed 5 years ago

riccardoporreca commented 5 years ago

On Windows, the VCS repository comparison does not work, due to Meld not detecting git / svn when launched via system2(..., wait = FALSE).

This is probably intrinsic in the behavior of system() / system2() and we cannot easily work around it. We also do not want to switch to wait = TRUE for windows.

A valid alternative seems to switch to package sys. A quick PoC of calling Meld via sys::exec_background("meld", ".") on Windows confirms VCS are detected.

We should replace system2() calls with equivalent sys functions everywhere in compareWith. Note that we have unit tests from https://github.com/miraisolutions/compareWith/issues/3#issuecomment-500467501 for the meld version check.

RolandASc commented 5 years ago

Closed by #28