kemayo / sublime-text-git

Plugin for some git integration into sublime text
MIT License
2.83k stars 390 forks source link

Use remote git executeable? #522

Closed AllanLRH closed 7 years ago

AllanLRH commented 7 years ago

Hi, is it possible to use a remote git executeable? I've tried telling the plugin to use the following script as my git executeable, but it's not working (and it was anyways a longshot):

#!/path/to/python/3.6

import subprocess
import sys

#  git command, add quotes for multiple words
cmd = ' '.join([f"'el'" if ' ' in el else el for el in sys.argv[1:]])
#  Construct full command line call-string
callStr = f'ssh usename@myserver.com "cd /project/folder && git {cmd}"'
#  Run the command
call = subprocess.Popen(callStr, shell=True)
call.wait()
call.terminate()

It works when I do a simple python36 myscript.py status, so guess it should also work when called from ST?

I need to use the remote git, since it's using a hook called nbstripout, in which some paths are hard coded to the server file system.

AllanLRH commented 7 years ago

Never mind, figured out a workaround, so that I don't need this. Closing this issue.