TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

QRCP: Transfer files to mobile device by scanning a QR code from the terminal

77 点作者 daw___大约 5 年前

4 条评论

daw___大约 5 年前
Author here, this is a refactoring of qr-filetransfer, already discussed in the past [0].<p>Here&#x27;s how it works: qrcp binds a web server to the address of your Wi-Fi network interface on a random port and creates a handler for it. The default handler serves the content and exits the program when the transfer is complete. When used to receive files, qrcp serves an upload page and handles the transfer.<p>The tool prints a QR code that encodes the text:<p><pre><code> http:&#x2F;&#x2F;{address}:{port}&#x2F;{random_path} </code></pre> Most QR apps can detect URLs in decoded text and act accordingly (i.e. open the decoded URL with the default browser), so when the QR code is scanned the content will begin downloading by the mobile browser.<p>To send one or more files (or directories):<p><pre><code> qrcp &#x2F;path&#x2F;to&#x2F;file # Or qrcp send &#x2F;path&#x2F;to&#x2F;file </code></pre> To receive one or more files:<p><pre><code> qrcp receive --output ~&#x2F;Downloads </code></pre> [0] <a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=16647977" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=16647977</a>
RMPR大约 5 年前
This is the feature I&#x27;m missing the most from KDE Connect, transferring from Computer to mobile, I ended up using syncthing with a &#x27;send_to_mobile&#x27; folder, not the main purpose but... it works.
评论 #22917099 未加载
hawski大约 5 年前
That is nice and delightfully simple.<p>When I saw the title I thought, that it will transfer a file entirely via continuous QR code scanning. But it would be probably too error prone and too slow, especially without a back channel to signify acks.<p>Maybe such a thing could work between two phones facing each other screens using front cameras. I wonder how fast could it practically get.
评论 #22943559 未加载
anderspitman大约 5 年前
Nice. I like that it goes over your local network and has a way to reverse transfer from the remote browser.