Results 1 to 9 of 9
  1. #1
    Join Date
    Apr 2010
    Posts
    1

    Thumbs up WinSCP custom command

    Hi,

    I was looking for instructions for how to make a custom command for WinsSCP and found none. So i started playing around with the command line options and found that this works nicely:

    Code:
    "C:\Program Files\Beyond Compare 3\BComp.exe" !&
    ...pretty simple. Works when selecting two or three files. Select one file also works but not useful. Select >3 also works but only three are compared.

    Thanks BC; your software continues to amaze (i just installed BC for Eclipse yesterday and WOW!).
    Ryan J Sullivan

  2. #2
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,908

    Default

    Thanks! User submissions such as this are always appreciated.
    Aaron P Scooter Software

  3. #3
    Join Date
    Feb 2012
    Posts
    3

    Default

    When using this command, BC come up and compares the files, but when I attempt to save one of the files, it does not propagate up through winscp and my changes appear in BC to be saved, but they are lost. I do not see attempt at activity (file xfer, etc.) in winScp when I do the save in BC.
    Do you know if there are other settings I should change to allow my saved changed to transfer back through winScp?
    thanks

  4. #4
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    2,525

    Default

    You'll have to take that up with the WinSCP developer. It's just downloading the content to temporary files and then launching BC with those. It would be up to them to notice that the files have changed and re-upload them.

    Alternatively, using Beyond Compare Pro, which supports SFTP natively.
    ZoŽ P Scooter Software

  5. #5
    Join Date
    Sep 2014
    Posts
    2

    Default

    Hi, Did you ever find a solution to this problem? I am experiencing the same issue.

    If I open a file any any of my external editors and save, WinSCP detects the changed temp file and uploads, but whenever I use a custom command to launch Beyond Compare, the saved temp file is lost.

    It would be great to figure this out, but I'm not sure whether it's WinSCP or Beyond Compare that is causing the problem.

    Thanks for posting

  6. #6
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    4,730

    Default

    Make sure you call bcomp.exe when launching Beyond Compare from WinSCP.

    This opens every compare and merge in a separate helper process, allowing version control to detect when the comparison is complete.

    If you use bcompare.exe, it opens all comparisons in a single process, so the launching application can't detect when the comparison is complete if you launch more than one diff.

    If you're using bcomp.exe and still seeing the problem, then you'll need to contact the makers of WinSCP for help or purchase Beyond Compare 3 Pro and use the SFTP support built into Beyond Compare.
    Chris K Scooter Software

  7. #7
    Join Date
    Sep 2014
    Posts
    2

    Default

    Hi,

    Thanks very much for your response.

    I've tried using BComp.exe, but the result is the same -- WinSCP doesn't detect the changed temp file and upload back to the server.

    It appears this may be by-design, I've found this in the WinSCP docs:

    Local commands that are executed on the local machine with remote files downloaded to a temporary folder. It makes no sense for the command to modify the files, because they are not uploaded back after the command finishes. You must have remote files selected first in order to execute the command.

    From: http://winscp.net/eng/docs/custom_command

    Thanks for your assistance.

  8. #8
    Join Date
    Jul 2016
    Posts
    1

    Default

    Quote Originally Posted by rgs258 View Post
    Code:
    "C:\Program Files\Beyond Compare 3\BComp.exe" !&
    .
    For anyone getting an error, make sure the 'Beyond Compare 3' portion of the path matches what you have installed, for example I'm on Beyond Compare 4

  9. #9
    Join Date
    Mar 2017
    Posts
    1

    Default

    This command seems to only where you want to compare two remote files. It doesn't work when one wants to compare local vs. remote file. In that cause use the following line:
    Code:
    "C:\Program Files\Beyond Compare 3\BComp.exe" "!" "!^!"

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •