Follow

Right, so, just so I’m sure I’ve covered all the bases. Options for getting rsync with ssh running on Windows 10 (not WSL):

- cygwin
- msys2
- A couple of incomplete cross-platform clones in Rust (none support ssh yet)

None of these are great options. There isn’t a statically-linked single binary (or better yet, pure JS option) I’ve missed, is there?

· · Web · 4 · 2 · 2

And just to elaborate: this is for embedding into a binary. So Docker, commercial stuff, etc., are out.

Update: I managed to get an up-to-date portable distribution of rsync and ssh from the cygwin project so that’s the route I’m going to take for now.

Thank you all for your suggestions and offers of help.

More info:

- source.small-tech.org/site.js/
- source.small-tech.org/site.js/

@aral i have found that git for windows packages a minimal msys that is less painful to deal with than getting msys from its original source, and I think it includes ssh and rsync.

@aral though now i think of it, it’s unclear to me how node/npm can work on windows without git, and therefore ssh and rsync somewhere it can access.

@aral SSH should be part of Windows 10 by default, maybe SCP is there, too? In that case maybe this is s close second?

@claudius I saw an issue yesterday where they (Microsoft) said rsync was “out of scope”.

🤷‍♂️

@claudius (And the OpenSSH they’re shipping now actually causes issues when you use the cygwin/msys2 rsync binaries.)

:awesome:

@aral oh! i did go looking for a way of embedding environments into single windows executables a while ago. the only solutions I could find were either commercial solutions, or elaborate low level C programming tricks to fake a file system with something like a resource database appended on the end of the exe.

@aral if you don’t want to dive into dotnet land (i certainly wouldn’t want to) the approach described there broadly doesn’t sound too terrible. self extracting archive puts files in hidden (or not) directory, then runs the main entry point- doesn’t extract again if run a second time.

@aral I've done Cygwin in the past, would generally recommend it.. Strongly suspect WSL should cover this as well.

Is there asnything vagguely Homebrew-esque for Windows?

@dredmorbius @aral winget is the one microsoft just out out. get it? like aptget. but..

@aral What's your rationale for excluding WSL? That would seem to be the straightforward route.

@dredmorbius @aral in short he’s porting site.js to windows and wants it to be a convenient self contained single file executable, and, i assume, it should run without requiring admin privileges.

@dredmorbius @aral (assumption based on what I would want if I were porting it)

@zensaiyuki @dredmorbius This.

Site.js does run under WSL but I’m not supporting right now as WSL and Windows 10 have different certificate trust stores and it’s a faff and a half to get localhost servers because of that on WSL and I don’t have time to devote to support at this point :) But will document that route for the future.

@aral Got it.

This problem you have could be worse: it could be mine.

Your suffering is an inspiration to us all.

@zensaiyuki

Sign in to participate in the conversation
Aral’s Mastodon

The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!