Sublime Forum

WinSCP "Integration"

#1

The 1.2 features announcement includes WinSCP Integration, though I havenā€™t seen any documentation or settings anywhere that actually do this.

Can someone help?

0 Likes

#2

You can use Sublime Text as WinSCPs editor by choosing it in WinSCPs preferences (under the ā€˜Editorsā€™ section). Youā€™ll need to check the ā€˜External editor opens multiple files in one window (process)ā€™ checkbox.

Some other options for working with files via SFTP are mentioned at viewtopic.php?f=4&t=674&start=0

0 Likes

#3

Eek thatā€™s what I was afraid Iā€™d learn.

Too bad, too, because I really really love the editor but thatā€™s just a deal-breaker for me. Iā€™m so used to Codaā€™s built-in ftp that itā€™s difficult to leave it.

0 Likes

#4

[quote=ā€œbmidgetā€]Eek thatā€™s what I was afraid Iā€™d learn.

Too bad, too, because I really really love the editor but thatā€™s just a deal-breaker for me. Iā€™m so used to Codaā€™s built-in ftp that itā€™s difficult to leave it.[/quote]

If u open any file in winscp with sublime as soon as you hit save it gets uploaded, and u can keep the file open for as long as you want and itā€™ll get uploaded on every change. Is good for making quick changes or when u have no option but to work on live server >.<
I donā€™t see how is a deal breaker :confused:

0 Likes

#5

The difference is not being able to use File | Open to open a remote file, which means you donā€™t need to switch out to winscp to find your file. That would definitely be a more integrated, elegant way of opening remote files. That said, driving it from winscp really isnā€™t a particular hardship, but having also used editors that do have it native, I can see the desire for it as an integrated feature.

Weā€™ve gone through something similar at work, where we provide the ability to read FTP and WebDAV as though they were local files. Itā€™s a hairy area, because as soon as you add ā€œFile | Open FTPā€¦ā€ to a menu, people expect to be able to do everything they can do with local files with remote files. So, people would expect projects to index FTP servers, and auto-reload when a file changes on the FTP server, and so on.

This opens up a whole mass of possible ā€˜file providersā€™, though ā€“ if jon writes FTP, why not WebDAV? Personally, if there were some custom interface available, Iā€™d be tempted to do one for wikis, so that you could open a wiki page as a file. Itā€™s a surprisingly large amount of work to do it ā€˜rightā€™.

0 Likes

#6

[quote=ā€œSteveCooperOrgā€]The difference is not being able to use File | Open to open a remote file, which means you donā€™t need to switch out to winscp to find your file. That would definitely be a more integrated, elegant way of opening remote files. That said, driving it from winscp really isnā€™t a particular hardship, but having also used editors that do have it native, I can see the desire for it as an integrated feature.

Weā€™ve gone through something similar at work, where we provide the ability to read FTP and WebDAV as though they were local files. Itā€™s a hairy area, because as soon as you add ā€œFile | Open FTPā€¦ā€ to a menu, people expect to be able to do everything they can do with local files with remote files. So, people would expect projects to index FTP servers, and auto-reload when a file changes on the FTP server, and so on.

This opens up a whole mass of possible ā€˜file providersā€™, though ā€“ if jon writes FTP, why not WebDAV? Personally, if there were some custom interface available, Iā€™d be tempted to do one for wikis, so that you could open a wiki page as a file. Itā€™s a surprisingly large amount of work to do it ā€˜rightā€™.[/quote]

I understand that, but I rather have sublime do 1 GREAT thing (powerful text editing) that try to do everything that others editors do and do it miserably, which is the case for many editors out thereā€¦
WinSCP is a great program (I use totalcmd now for FTP tho), if a simple alt+tab or switching to it is too painful then I donā€™t really see how is a sublimetext problem but rather a userā€™s preference problem.

and Like you said, it just brings more bugs to the table :stuck_out_tongue:
If itā€™s a plugin Iā€™m all for it, built-in, no thx. keep it simple :smiley:

0 Likes

#7

i too support the unix approach, i.e. one tool for each task. imo, if you start doing too much in one program/solution you end up with actually limiting the user. this is why i donā€™t use IDEs at all. i like to choose what i like, for every task.

0 Likes

#8

Winscp is scriptable, meaning that a plugin is possible. Opening and saving to ftp could be integrated.

0 Likes

#9

WinSCP scripting:

"C:\Program Files\WinSCP3\winscp" /script open "mySavedSessionName" get /export/home/myuser/mytestfile.txt c:\localFolder\ keepuptodate c:\localFolder /export/home/myuser <hit Ctrl-C when done> exit

If you know the file path/name that you want to edit, this would be simple enough to integrate in a plugin, except maybe the Ctrl-C part

0 Likes

#10

Sublimatorā€¦? :smiley:

0 Likes

#11

For those specifically interested in using WinSCP, I started to develop a plugin, please check this thread:
http://www.sublimetext.com/forum/viewtopic.php?f=6&t=740&start=0

0 Likes

#12

What would be good is to have a project window file explorer within sublime, this can then be configured to match a remote destination, so all files are local, but can easily be transferred to the remote server without the need to switch windows, navigate multiple file paths, etc

Iā€™ve been using dreamweaver and the only reason I still do is because of this, editing remote files is not a realistic option as I need to commit files to svn, I have long been searching for a simple text editor that supports projects in this way so I can get away from dreamweaver as itā€™s such a pig to use and itā€™s code colouring support is very weak, I use a dark theme but every so often it decides some parts of files are unrecognisable so it defaults back to black text making it unreadable on a dark background, where as sublime is good and hasnā€™t shown any of these characteristics

0 Likes

#13

[quote=ā€œlogginā€]What would be good is to have a project window file explorer within sublime, this can then be configured to match a remote destination, so all files are local, but can easily be transferred to the remote server without the need to switch windows, navigate multiple file paths, etc

Iā€™ve been using dreamweaver and the only reason I still do is because of this, editing remote files is not a realistic option as I need to commit files to svn, I have long been searching for a simple text editor that supports projects in this way so I can get away from dreamweaver as itā€™s such a pig to use and itā€™s code colouring support is very weak, I use a dark theme but every so often it decides some parts of files are unrecognisable so it defaults back to black text making it unreadable on a dark background, where as sublime is good and hasnā€™t shown any of these characteristics[/quote]

have u tried software mentioned here? I did in the past when I didnt use total commander and they did their job good. But I like total commander because it can do exactly what you say, keep files locals and keep it sync on remote location. I really donā€™t mind the switching to windows is just one shortcut away >.< besides I rather have a full blown very powerful file manager than sublime trying to do everything.

0 Likes

#14

webdrive isnā€™t practical when you have to dip in and out of as many projects as I have to, plus Iā€™ve still got to use an svn client and this would just litter the site with inappropriate files.

Iā€™m having a look at total commander but canā€™t see a way to set it to automatically send files without any interaction, all I want to do is hit ctrl+s and then look at the results in a browser, in any other interaction is just clumsy and annoying.

Iā€™ve been there in the past where Iā€™ve managed sites using textpad32 and a separate ftp client but believe me once you get away from it you really do wonder how you managed before, and Iā€™ve spent the years since moving away nagging in their forums with many others asking for just this sort of feature, but the arrogance of their developers had meant Iā€™d given hope but will sublime come to the rescue until such a feature exists these text editors are nothing more than notepad with pretty colours ( and some useful macros ) and are not serious development environments

mind you dreamweaver does go to far and always seems to using its rendering engine even when you only ever use code view.

I canā€™t win, lol, I know Iā€™m not alone in my wants

0 Likes

#15

[quote=ā€œlogginā€]webdrive isnā€™t practical when you have to dip in and out of as many projects as I have to, plus Iā€™ve still got to use an svn client and this would just litter the site with inappropriate files.

Iā€™m having a look at total commander but canā€™t see a way to set it to automatically send files without any interaction, all I want to do is hit ctrl+s and then look at the results in a browser, in any other interaction is just clumsy and annoying.

Iā€™ve been there in the past where Iā€™ve managed sites using textpad32 and a separate ftp client but believe me once you get away from it you really do wonder how you managed before, and Iā€™ve spent the years since moving away nagging in their forums with many others asking for just this sort of feature, but the arrogance of their developers had meant Iā€™d given hope but will sublime come to the rescue until such a feature exists these text editors are nothing more than notepad with pretty colours ( and some useful macros ) and are not serious development environments

mind you dreamweaver does go to far and always seems to using its rendering engine even when you only ever use code view.

I canā€™t win, lol, I know Iā€™m not alone in my wants[/quote]

WinSCP does this by the way. And I believe they have some kind of monitor to keep local folders in sync with remote locationsā€¦ I think WinSCP can help definetely.

EDIT:
winscp.net/eng/docs/task_keep_up_to_date

Sounds like a win to me.

0 Likes

#16

Sadly WinSCP craps itself trying to scan all the directories on some of our larger projects :frowning: and really actively scanning a file system for changes canā€™t be that efficient when all thats required is a hook when a file is saved.

It also doesnā€™t like not being synced, which is totally inpractical as some of our clients upload thousands of files to their sites, documents, images, etc so getting all these files locally can slow down the time to start doing the actual work.

I understand some people donā€™t want it, especially those that donā€™t work with the web, which is fair enough, but there must some way to enable the feature as a decent plugin that can be chosen by those that do want it.

0 Likes

#17

[quote=ā€œlogginā€]Sadly WinSCP craps itself trying to scan all the directories on some of our larger projects :frowning: and really actively scanning a file system for changes canā€™t be that efficient when all thats required is a hook when a file is saved.

It also doesnā€™t like not being synced, which is totally inpractical as some of our clients upload thousands of files to their sites, documents, images, etc so getting all these files locally can slow down the time to start doing the actual work.

I understand some people donā€™t want it, especially those that donā€™t work with the web, which is fair enough, but there must some way to enable the feature as a decent plugin that can be chosen by those that do want it.[/quote]

sublime support those hooks already. onPreSaveand onPostSave I guess you could hook into onPostSaveand do the upload calling winscp from command line thru a plugin.

0 Likes