Has anyone looked into Clojure 1.12 and param tags to simplify clj-ssh code ? From memory it was complex to deal with arity of the underlying java libs. Or is there a more recent ssh java lib?
Maybe you can try https://github.com/epiccastle/spire?
Also this https://github.com/epiccastle/bbssh?tab=readme-ov-file
Requiring 1.12 is not a great idea for a library at this early stage. In a year, maybe.
(or did you just mean in your own application code? If so, can you give an example @bocaj?)
Good point, this would need to be a new library perhaps. Just thinking of looking into how simple use of jsch could get.
I found jsch Channel useful here https://github.com/Jacob-Kroeze/tech.io.sftp/blob/main/src/tech/v3/io/sftp_client.clj but couldn’t use it easily because of overloading to java. I’m exploring if it would be worth adding to clj-ssh or if anyone else would be interested in a yet another ssh library. Or is my hunch correct that some wrapper libraries like clj-ssh can be written more clearly now?
Oh, I'm sure the library code could be cleaned up if it used 1.12... in our code at work, the places where we do heavy interop are cleaner on 1.12 (we have it in production already -- we've had every prerelease build in production for over 13 years).
Great! 🙂
That Jacob Kroeze lib depends on clj-ssh. Maybe you could either add to that or provide a similar add-on to clj-ssh?
At work, we haven't needed much for sftp operations. We just use com.hierynomus/sshj {:mvn/version "0.39.0"} and a bit of Java interop.
The interop to do basic sftp ops is very straightforward and we haven't had to touch it for at least 3 years (I just checked).
I wasn’t aware of that library and licenses look more clear. Thanks!