Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

From my experience, it's possible to just do

  ssh host 'ls "folder name"'
and practically ignore the `command [arguments]` split in SSHs synopsis. It's all passed to a shell and parsed again, anyway.


For simple tasks, that's how I have always done it.

Alternatively,

   echo ls \"folder name\"|ssh -T host
or

   cat > 1
   ls "folder name"
   ^D

   ssh -T host < 1


The last example really looks like perfect case for using `here document` feature.

    ssh -T host <<EOF
    ls "folder name"
    EOF




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: