-
I'm not the best on javascript programming however using ssh2 I can get it to work in the "global" the namespace of the file aka ssh.cljs. However when I try to put the code in a function I keep getting non working code (that works if you put in "global" namespace of file but just not in the ssh-exec fn The code doesnt work if I pass in the Client constructor into the function either Sorry if this is a noob question |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
@frap I don't know how this-as relates to your question, but I made an example with ssh2 here now: https://github.com/babashka/nbb/blob/main/examples/ssh2/example.cljs It also shows a promise-based approach using promise and ssh2-promise which might be more convenient. |
Beta Was this translation helpful? Give feedback.
@frap I don't know how this-as relates to your question, but I made an example with ssh2 here now:
https://github.com/babashka/nbb/blob/main/examples/ssh2/example.cljs
It also shows a promise-based approach using promise and ssh2-promise which might be more convenient.