dasuchin / grunt-ssh-deploy

Grunt SSH Deployment
MIT License
66 stars 45 forks source link

Symlink not being created in version 0.2.9 #39

Closed aborovsky closed 9 years ago

aborovsky commented 9 years ago

With version 0.2.8 evertything is fine. But in version 0.2.8 thing going wrong:

  1. Release dir created successfully (mkdir)
  2. Release uploaded successfully (scp)
  3. Symlink creation (ln -s) is done silently without errors.
  4. But no symplink in place, where it supposed to be!

Log of success execution of grunt-ssh-deploy v0.2.9:

[4m Running "ssh_deploy:example_deploy" (ssh_deploy) task
[24m
[D] 
[35m Task source: c:\path_to_project\node_modules\example-gruntproject\node_modules\grunt-ssh-deploy\tasks\ssh_deploy.js
[39m

[1mConnecting :: example.site[22m
[1mConnected :: example.site[22m

[1m--------------- CREATING NEW RELEASE[22m

[1m--- cd /home/example/www/example_deploy/v2 && mkdir -p releases/20150729104953742
[22m
[D] 
[35m REMOTE: cd /home/example/www/example_deploy/v2 && mkdir -p releases/20150729104953742
[39m
[1m--------------- UPLOADING NEW BUILD
[22m
[D] 
[35m SCP FROM LOCAL: build/example_deploy
 TO REMOTE: /home/example/www/example_deploy/v2/releases/20150729104953742/
[39m

[1m--- DONE UPLOADING
[22m
[1m--------------- UPDATING SYM LINK
[22m
[1m--- rm -rf /home/example/www/example_deploy/v2/3eec74c8097f713f897650a8d4ad7ec9 && ln -s /home/example/www/example_deploy/v2/releases/20150729104953742 /home/example/www/example_deploy/v2/3eec74c8097f713f897650a8d4ad7ec9
[35m REMOTE: rm -rf /home/example/www/example_deploy/v2/3eec74c8097f713f897650a8d4ad7ec9 && ln -s /home/example/www/example_deploy/v2/releases/20150729104953742 /home/example/www/example_deploy/v2/3eec74c8097f713f897650a8d4ad7ec9
[39m
[32mDone, without errors.
[39m

And fail execution of grunt-ssh-deploy v0.2.8:

[4mRunning "ssh_deploy:example_deploy" (ssh_deploy) task
[24m
[D] 
[35m Task source: C:\path_to_project\example-gruntproject\node_modules\grunt-ssh-deploy\tasks\ssh_deploy.js
[39m
[1mConnecting :: example.site
[22m
[1mConnected :: example.site
[22m
[1m--------------- CREATING NEW RELEASE
[22m
[1m--- mkdir -p \home\example\www\example_deploy\v2\releases\20150729110150023
[22m
[D] 
[35mREMOTE: mkdir -p \home\example\www\example_deploy\v2\releases\20150729110150023
[39m
[1m--------------- UPLOADING NEW BUILD
[22m
[D] 
[35mSCP FROM LOCAL: build/example_deploy
 TO REMOTE: \home\example\www\example_deploy\v2\releases\20150729110150023
[39m
[1m--- DONE UPLOADING
[22m
[1m--------------- UPDATING SYM LINK
[22m
[1m--- rm -rf \home\example\www\example_deploy\v2\3eec74c8097f713f897650a8d4ad7ec9 && ln -s \home\example\www\example_deploy\v2\releases\20150729110150023 \home\example\www\example_deploy\v2\3eec74c8097f713f897650a8d4ad7ec9
[22m
[D] 
[35mREMOTE: rm -rf \home\example\www\example_deploy\v2\3eec74c8097f713f897650a8d4ad7ec9 && ln -s \home\example\www\example_deploy\v2\releases\20150729110150023 \home\example\www\example_deploy\v2\3eec74c8097f713f897650a8d4ad7ec9
[39m
[32mDone, without errors.
[39m

Suppose, ploblem here:

[35mREMOTE: rm -rf \home\example\www\example_deploy\v2\3eec74c8097f713f897650a8d4ad7ec9 && ln -s \home\example\www\example_deploy\v2\releases\20150729110150023 \home\example\www\example_deploy\v2\3eec74c8097f713f897650a8d4ad7ec9

Backslashes instead of straight slashes!

dasuchin commented 9 years ago

Should be fixed in latest version.

oualid13 commented 7 years ago

Hi, I have the same issue in version 0.4.1.