-
Notifications
You must be signed in to change notification settings - Fork 605
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
--write-code-to-fd= : machine readable wormhole code #104
Comments
What language is your application written in? I'm eager to see alternate implementations in other languages. For arbitrary shell-type stuff, you might consider having the GUI application decide upon the code itself (randomly picking channel-id and words), and pass it in, as That said, I think something like |
Haskell. But while a wormhole reimplementation in haskell would be super useful for me, I don't have time to build it right now and am stuck in shell scripting mode, or perhaps with writing a small python script using the wormhole libraries. I wouldn't mind using my own wordlist, but possibility of channel id collisions seems too problematic. --write-code-to-fd=5 would be perfect.. |
#85 is where --write-code-to-fd= was previously suggested. |
aha, thanks |
After I filed this bug, and had implemented a hack to parse magic-wormhole's stdout and identify the wormhole code, 72dfb6e changed it to output to stderr. Unfortunately this means that git-annex's magic wormhole integration has been broken for years, and is likely to remain broken for longer since it's unlikely a fix will reach eg Debian stable. Please please please provide an API for this so further such breakage can be avoided. Otherwise, I may need to reconsider using magic-wormhole. |
Ah, I'm so sorry. How hard/disruptive would it be for git-annex to include a small Python program which used the internal Wormhole API directly? That API is pretty stable, whereas the CLI tool's behavior is more up in the air (I know localization is a problem too). One nuisance is that if you're currently using plain That said, I think the
The receiving side should be similar. Lemme know if this looks promising, I can help get those scripts get written. |
A GUI application that uses magic wormhole would need to either open a terminal for the user to see the wormhole code, or could parse the wormhole send output to find the wormhole code. Neither option seems ideal. Would it be reasonable to have a mode where the wormhole code is output in a machine readable fashion, eg as the only output to stdout?
(This might be the kind of use case where it'd be better to use the magic wormhole library, but my application is not written in python.)
The text was updated successfully, but these errors were encountered: