inossidabile / grunt-ftpush

Grunt task for incremental code deployment over ftp

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Bad path on server, impossible upload

silverqx opened this issue · comments

Configuration:

        ftpush: {
            build: {
                auth: {
                    host: 'ftp.vlastne-byvanie.sk',
                    port: 21,
                    authKey: 'key1'
                },
                src: 'tt',
                dest: '/a'
            }
        }

grunt-contrib-ftp

I have tried many combinations of src-dest, but without success.

On the server is created dir with name \a\ ( dir with name a should be created ) and the same with files.

Now I have tried grunt-ftp-deploy and it works without problems.

The structure of uploaded folder is like this:

\
|- somefolder1
|- somefolder2
|- tt ( I'm trying to upload this folder )
   |- appEnv.php
   |- closure-problem.html
   |- closure-problem-data.html

After upload it looks on the server like this:

\
|- tmp ( some other dir, not uploaded )
|- www_root ( some other dir, not uploaded )
|- \a\ ( should be folder with name a, but it's folder with name \a\ )
|- \a\appEnv.php ( this file should be in folder a, but it's in root and have name \a\appEnv.php )
|- \a\closure-problem.html ( the same behavior like appEnv.php file )
|- \a\closure-problem-data.html

And when the dest param isn't dest: '/a', but have value dest: 'a', so the structure looks like this:

\
|- tmp ( some other dir, not uploaded )
|- www_root ( some other dir, not uploaded )
|- a\ ( should be folder with name a, but it's folder with name a\ )
|- a\appEnv.php ( this file should be in folder a, but it's in root and have name a\appEnv.php )
|- a\closure-problem.html ( the same behavior like appEnv.php file )
|- a\closure-problem-data.html

I don't understand coffee script, but I suppose that problem may be in escaping.

I belive the problem comes from slashes. It tries to use the slash style of your local system. While it should use the style of remote one. I don't have much time right now but I'll try to get back ASAP.

Ok, thank you, I'm on Windows now.

Please try 0.3.0. Closing the issue, please reopen if you need further assistance.

I have tried it and it works now, thank you.

Slashes printed into the console are correct as wel, now are \ before was /.

Good. Glad to hear that.