vscode-ftp-sync icon indicating copy to clipboard operation
vscode-ftp-sync copied to clipboard

Cannot disable uploadOnSave. even when it's false !!!

Open rostamiani opened this issue 6 years ago • 11 comments

I cannot disable uploadOnSave. The file always get uploaded after saving. This is the configuration:

{ "remotePath": "/public_html/charge/", "host": "ftp.clicktocall.net", "username": "profilet", "password": "7o4Yv4iVo2", "port": 21, "secure": false, "protocol": "ftp", "uploadOnSave": false, "passive": false, "debug": false, "privateKeyPath": null, "passphrase": null, "agent": null, "allow": [], "ignore": [ "\.vscode", "\.git", "\.DS_Store" ], "generatedFiles": { "extensionsToInclude": [ "" ], "path": "" } }

rostamiani avatar Jan 02 '19 08:01 rostamiani

I have the same problem. It seems to be a bug in the latest version. Try a previous version - it will work.

sbberni avatar Jan 05 '19 17:01 sbberni

Download latest version from this github repository. It solves the issue.

NajSurf avatar Jan 06 '19 18:01 NajSurf

@NajSurf Any idea when this update will be pushed to vscode?

frobinsonj avatar Jan 15 '19 11:01 frobinsonj

I'm using the latest version, downloaded from this GitHub repository, but I'm still not able to disable "uploadOnSave" when set to false. Anyone any suggestions?

SijbenR avatar Jan 27 '19 10:01 SijbenR

I have the same problem. :-(

SimbaRemiu avatar Feb 07 '19 14:02 SimbaRemiu

Same problem here (2019-03-04), 'uploadOnSave' is always true for the extension. No matter what you choose. It's annoying because in some scenarios you DO NOT want the file to auto upload.

Edit: I add some info for the developers.

I use SFTP (secure: true, port 22) with RSA key to connect. Passive mode false.

elvirtu avatar Mar 04 '19 12:03 elvirtu

I have the same problem,even if it's update to v0.4.0

hldjlz avatar Mar 18 '19 01:03 hldjlz

Same here. The worst is that if you change the branch, it will start to upload all changed files, causing a freaking mess in the remote repository the FTP is pointing to. I had to modify the host so it stop FTPing without my consent.

Linux: Ubuntu 18.04 / Manjaro latest VScode: 1.33.0 ftp-sync: 0.3.9

ftp-sync.json:

{
    "remotePath": "/web/websys/dev",
    "host": "Xmyhost",
    "username": "myuser",
    "password": "mypass",
    "port": 21,
    "protocol": "ftp",
    "uploadOnSave": false,
    "passive": false,
    "debug": false,
    "privateKeyPath": null,
    "ignore": [
        "\\.git"
    ]
}

EthraZa avatar Apr 08 '19 12:04 EthraZa

Same here. Probably it's a small thing but it is important to solve it.

JordiTR avatar May 05 '19 18:05 JordiTR

I have the same problem. It seems to be a bug in the latest version. Try a previous version - it will work.

Yeah it works

haunt07 avatar Oct 10 '20 00:10 haunt07

Edit the following file to FIX:-

For Windows: C:\Users\(user)\.vscode\extensions\lukasz-wronski.ftp-sync-0.3.9\modules\on-generate.js For Linux: home/(user)/.vscode/extensions/lukasz-wronski.ftp-sync-0.3.9/modules/on-generate.js

File will look like this:

module.exports = function(document, getFtpSync, skipOnSaveCheck) {
if (document.uri.fsPath.indexOf(ftpconfig.rootPath().fsPath) < 0) return;
var config = ftpconfig.getConfig();

if (!config.uploadOnSave) return; // <------ ADD THIS LINE TO FIX

murad-faridi avatar Oct 13 '21 06:10 murad-faridi