Home Download Buy Blog Forum Support

Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Re: Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Postby wbond on Sat Mar 24, 2012 1:23 pm

ricochet1k wrote:
wbond wrote:It would take as much time as it currently does to do a remote -> local sync. The slow part is recursively parsing every remote folder to see the current contents. Normally when syncing remotely to locally there aren't that many files changed. It is usually that a user has a large folder structure, or a connection that is no super-fast that causes it to be slow process.

I get that downloading the list of files is slow (FTP is slow as a general rule) but it wouldn't have to download all the files. It could just create blank ones to match the structure of the remote machine.


No, it doesn't need to download all files, but it needs to list every remote folder to find all of the files to replicate as blank files. That process of listing folders tends to be pretty slow for lots of servers.

ricochet1k wrote:
wbond wrote:For users that want to work on remote files as if they were local, with the full functionality of Sublime, you should try out http://www.expandrive.com. Some users find it fast enough, other find it too laggy.

ExpanDrive doesn't work on Linux. Filezilla has the ability to edit remote files using temporaries too. SFTP is better anyway. Seeing all the files listed in the sidebar is mostly just a convenience, albeit a very nice one.


It is actually way simpler, and free, on Linux using sshfs. Here is some example documentation: https://help.ubuntu.com/community/SSHFS. Expandrive on OS X basically does the same thing using fuse, with a bit more polish, and a simpler setup. You can set up straight up sshfs also though: http://www.turingtarpit.com/2009/04/mou ... macfusion/.

ricochet1k wrote:Also, an irritation I found when trying to download several individual files using the quick panel is that it disappears when the bottom panel is closed, so downloading several files in a row (from multiple folders) is a bit frustrating with auto-close turned on. Would it be possible to delay closing the panel at least until the quick-panel has been closed?


Unfortunately there is no way to tell when the quick panel is open, and the command that closes the SFTP panel also ends up closing the quick panel. That said, the output panel does not seem to hide after downloading a file. For most (if not all) server workflow operations I skip hiding the SFTP output panel so that the quick panel is not closed inadvertently. Instead, I am just not re-opening the quick panel since I make the assumption that if you want to download a file, it is to edit it.
wbond
 
Posts: 493
Joined: Mon Feb 28, 2011 5:33 am

Re: Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Postby elkraneo on Mon Mar 26, 2012 8:48 pm

trying to setup a "remote_path": "/", but keeps uploading all my local path "/Users/blabla/project/deploy" to remote...what im missing ?

thx in advance
elkraneo
 
Posts: 3
Joined: Wed Jan 04, 2012 10:28 am

Re: Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Postby kuku on Sun Apr 08, 2012 6:23 am

Hey!

i have one question about SFTP and FTP plugin "ignore_regex" param. Is it possible, to ignore folder/subfolder/files with some extension?
For example:
I need to ignore all *.xls files in this directory files/docs/
ignore_regex - files/docs - works for all files, but files/docs/*//.xls doesn't.

P.s. i'm not good on regex, so i think there should be some regex, for my problem :)

Any help is welcome! Thanks in advance :)
kuku
 
Posts: 1
Joined: Sun Apr 08, 2012 5:27 am

Re: Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Postby wbond on Sun Apr 08, 2012 11:49 pm

elkraneo wrote:trying to setup a "remote_path": "/", but keeps uploading all my local path "/Users/blabla/project/deploy" to remote...what im missing ?

thx in advance


What local folder do you have your sftp-config.json in? If you set the remote_path to /, your local path will be converted to / on the remote system. For example, if sftp-config.json is inside of /home/will/files/ and the remote path is /, then uploading /home/will/files/css/main.css will upload it to /css/main.css.
wbond
 
Posts: 493
Joined: Mon Feb 28, 2011 5:33 am

Re: Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Postby wbond on Sun Apr 08, 2012 11:56 pm

kuku wrote:Hey!

i have one question about SFTP and FTP plugin "ignore_regex" param. Is it possible, to ignore folder/subfolder/files with some extension?
For example:
I need to ignore all *.xls files in this directory files/docs/
ignore_regex - files/docs - works for all files, but files/docs/*//.xls doesn't.

P.s. i'm not good on regex, so i think there should be some regex, for my problem :)

Any help is welcome! Thanks in advance :)


The following takes the default ignore_regex and adds all .xls files inside of files/docs to the list:

Code: Select all
"(files/docs/.*\\.xls|\\.sublime-project|\\.sublime-workspace|sftp-config(-alt\\d?)?\\.json|sftp-settings\\.json|/venv/|\\.svn|\\.hg|\\.git|\\.bzr|_darcs|CVS|\\.DS_Store|Thumbs\\.db|desktop\\.ini)"
wbond
 
Posts: 493
Joined: Mon Feb 28, 2011 5:33 am

Re: Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Postby craigpatik on Sat Apr 21, 2012 10:55 pm

Has anyone experienced an issue in OSX where SFTP seems to stop working after putting the MacBook to sleep? I can't reproduce it every time, but it generally goes like this:
1. Use Sublime as usual and upload files at will
2. Close the MacBook lid
3. Open the lid and start using Sublime again
4. Try to upload a file (the active/open file, using a keyboard shortcut)

The quick panel opens, but no new "Uploading..." line appears. Instead I just see the same log that was present before, and the quick panel never changes or closes. The file does not get uploaded either. The only way to 'wake up' SFTP seems to be by quitting and reopening Sublime. (Is there a way I can try to manually restart just SFTP via the console?)
craigpatik
 
Posts: 12
Joined: Mon Jan 09, 2012 2:26 pm

Re: Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Postby craigpatik on Sun Apr 22, 2012 11:40 am

Is this the appropriate place to post feature requests? (Is there even an appropriate place for that? :) )

I'd love to be able to set up an 'alias', so that when I try to upload:
Code: Select all
~/project/less/styles.less

Instead, SFTP will upload:
Code: Select all
~/project/css/styles.css


Currently, I only edit the LESS file (the CSS is auto-generated in the background) and it gets a bit tedious to manually open or locate the CSS file separately just to upload it. Obviously this could be extended to other languages and workflows (e.g., minified/concatenated versions of the file you're editing, compiled versions of a file, etc).
craigpatik
 
Posts: 12
Joined: Mon Jan 09, 2012 2:26 pm

Re: Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Postby wbond on Mon Apr 23, 2012 3:23 am

craigpatik wrote:Has anyone experienced an issue in OSX where SFTP seems to stop working after putting the MacBook to sleep? I can't reproduce it every time, but it generally goes like this:
1. Use Sublime as usual and upload files at will
2. Close the MacBook lid
3. Open the lid and start using Sublime again
4. Try to upload a file (the active/open file, using a keyboard shortcut)

The quick panel opens, but no new "Uploading..." line appears. Instead I just see the same log that was present before, and the quick panel never changes or closes. The file does not get uploaded either. The only way to 'wake up' SFTP seems to be by quitting and reopening Sublime. (Is there a way I can try to manually restart just SFTP via the console?)


When you machine goes to sleep, most likely your SFTP session is being lost, but not properly closed. When you awaken your machine, it will try to send a command and likely will fail after the default timeout for sftp on your platform. You probably will want to cancel the operation and try again:

http://wbond.net/sublime_packages/sftp/ ... _Workflows
wbond
 
Posts: 493
Joined: Mon Feb 28, 2011 5:33 am

Re: Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Postby wbond on Mon Apr 23, 2012 3:28 am

craigpatik wrote:Is this the appropriate place to post feature requests? (Is there even an appropriate place for that? :) )

I'd love to be able to set up an 'alias', so that when I try to upload:
Code: Select all
~/project/less/styles.less

Instead, SFTP will upload:
Code: Select all
~/project/css/styles.css


Currently, I only edit the LESS file (the CSS is auto-generated in the background) and it gets a bit tedious to manually open or locate the CSS file separately just to upload it. Obviously this could be extended to other languages and workflows (e.g., minified/concatenated versions of the file you're editing, compiled versions of a file, etc).


You can certainly post items here, however things can slip by since there are no notification for this forum. If you email me at support@wbond.net, you can be sure to get a response.

The desired functionality you are looking for will be available soon, albeit implemented in a slightly different way. I've been working on getting file modification notifications working well with the SVN package, after which I plan to port that functionality to SFTP. This will allow the package to automatically upload all files when they change, rather than just files saved by Sublime.

Until then you can use the Monitor File (http://wbond.net/sublime_packages/sftp/ ... nitor_File) command with the .less file open. This polls the file stats waiting for the modification time to change, after which it will be uploaded. Just be aware the file must remain open in Sublime for this to work.
wbond
 
Posts: 493
Joined: Mon Feb 28, 2011 5:33 am

Re: Sublime SFTP and FTP Plugin (w/ Remote Browsing)

Postby chodorowicz on Tue Apr 24, 2012 4:29 pm

wbond wrote:
craigpatik wrote:Is this the appropriate place to post feature requests? (Is there even an appropriate place for that? :) )

I'd love to be able to set up an 'alias', so that when I try to upload:
Code: Select all
~/project/less/styles.less

Instead, SFTP will upload:
Code: Select all
~/project/css/styles.css


Currently, I only edit the LESS file (the CSS is auto-generated in the background) and it gets a bit tedious to manually open or locate the CSS file separately just to upload it. Obviously this could be extended to other languages and workflows (e.g., minified/concatenated versions of the file you're editing, compiled versions of a file, etc).


Until then you can use the Monitor File (http://wbond.net/sublime_packages/sftp/ ... nitor_File) command with the .less file open. This polls the file stats waiting for the modification time to change, after which it will be uploaded. Just be aware the file must remain open in Sublime for this to work.

Yep, "monitor file" works perfectly for me in exactly the same situation - I'm editing less file, external app compiles it and then SFTP plugins uploads monitored *.css file.
chodorowicz
 
Posts: 18
Joined: Tue Oct 11, 2011 4:04 pm

PreviousNext

Return to Plugin Announcements

Who is online

Users browsing this forum: No registered users and 12 guests

cron