Skip to main content

qshare

无需登录账号,一行命令即可把本地文件临时分享至公网。文件由本机 HTTP 服务提供,并通过临时 TryCloudflare 隧道传输,不会上传到 qshare 服务器留存。

特点

  • 无需注册或登录账号
  • 一行命令快速分享本地文件
  • 文件不在 qshare 服务器保存
  • 默认有效期 2 小时,可通过 --ttl 调整
  • 结果链接醒目显示,并提供终端二维码
  • 支持 Linux、Windows 和 macOS
  • PyPI 平台 wheel 内置对应的官方 cloudflared 二进制
  • 运行时不从 GitHub 下载二进制,适合网络受限环境

安装

python -m pip install -U qshare

pip 会根据操作系统和架构选择对应 wheel,每个 wheel 只包含自身平台的二进制。

如果不信任 PyPI wheel 中的二进制,可以从 Cloudflare 官方发布页下载匹配版本,按官方校验和验证后放入 PATH:

https://github.com/cloudflare/cloudflared/releases

qshare 会优先使用 PATH 中已有的 cloudflared。没有匹配平台 wheel 时,也可以手动安装 cloudflared 后使用。

使用

qshare /path/to/file.zip
qshare /path/to/file.zip --ttl 2h
qshare /path/to/file.zip --ttl 900
qshare /path/to/file.zip --port 8000

成功后会显示醒目的公网文件链接及二维码。程序只接受真实的 *.trycloudflare.com 分享域名,会拒绝 api.trycloudflare.com 并自动重试。Unix-like 系统可在提示处输入 d 后台运行;Windows 始终前台运行。前台运行达到 TTL 后会提示并停止分享。

DNS 排查

如果打开链接时提示找不到 IP,通常是本地 DNS 解析或网络限制。可以尝试使用 Cloudflare DNS 1.1.1.1、1.0.0.1,或 Google DNS 8.8.8.8、8.8.4.4,然后刷新本地 DNS 缓存并重试。1.1.1.1 可能改善解析,但无法解决隧道过期或网络屏蔽 Cloudflare 的问题。

开发与发布

uv venv
source .venv/bin/activate
uv pip install -e .
PYTHONPATH=src pytest -q

使用本地准备好的 Cloudflare 二进制构建平台 wheel:

uv build
python scripts/build_platform_wheels.py --assets-dir /path/to/cloudflared-assets

说明

  • 默认有效期为 2 小时。
  • 端口被占用时会自动选择其他空闲端口。
  • --ttl 支持 30m、90s、2h 或秒数。

Metadata

Release files for qshare 0.2.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for qshare 0.2.3
File Size Uploaded Provenance Actions
qshare-0.2.3.tar.gz 7.8 kB Without provenance Details for qshare-0.2.3.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for qshare 0.2.3
File Actions
qshare-0.2.3-py3-none-win_amd64.whl Python 3 none Windows x86-64 Details for qshare-0.2.3-py3-none-win_amd64.whl
qshare-0.2.3-py3-none-win32.whl Python 3 none Windows x86-32 Details for qshare-0.2.3-py3-none-win32.whl
qshare-0.2.3-py3-none-manylinux_2_17_armv7l.whl Python 3 none Linux glibc 2.17+ ARMv7l Details for qshare-0.2.3-py3-none-manylinux_2_17_armv7l.whl
qshare-0.2.3-py3-none-manylinux2014_x86_64.whl Python 3 none Linux glibc 2.17+ x86-64 Details for qshare-0.2.3-py3-none-manylinux2014_x86_64.whl
qshare-0.2.3-py3-none-manylinux2014_i686.whl Python 3 none Linux glibc 2.17+ x86-32 Details for qshare-0.2.3-py3-none-manylinux2014_i686.whl
qshare-0.2.3-py3-none-manylinux2014_aarch64.whl Python 3 none Linux glibc 2.17+ ARM64 Details for qshare-0.2.3-py3-none-manylinux2014_aarch64.whl
qshare-0.2.3-py3-none-macosx_11_0_arm64.whl Python 3 none macOS 11.0+ ARM64 Details for qshare-0.2.3-py3-none-macosx_11_0_arm64.whl
qshare-0.2.3-py3-none-macosx_10_13_x86_64.whl Python 3 none macOS 10.13+ x86-64 Details for qshare-0.2.3-py3-none-macosx_10_13_x86_64.whl
qshare-0.2.3-py3-none-linux_armv6l.whl Python 3 none linux armv6l Details for qshare-0.2.3-py3-none-linux_armv6l.whl

Total release size: 168.0 MB

Release files / qshare-0.2.3.tar.gz

Download URL qshare-0.2.3.tar.gz
Size 7.8 kB
Tags Source
SHA-256 checksum
How to use checksums
b923853f149e0bc7904ea1c6e58e2b9784d676a606a3fedf182088f0a647f578
BLAKE2b-256 checksum
How to use checksums
bb53d509827d75516fbda036753f1de42e7b0c99b30ef93d77a77221f84ab961
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / qshare-0.2.3-py3-none-win_amd64.whl

Download URL qshare-0.2.3-py3-none-win_amd64.whl
Size 18.4 MB
Tags Python 3 Windows x86-64
SHA-256 checksum
How to use checksums
5be619a4e824369f609ee2b62d15167a2c32d1447be54996cda0fb808fe4a2f8
BLAKE2b-256 checksum
How to use checksums
b26c9308a7469682a979166c3228bdc6bfc82ac4f42d4c56e4ab4246b8ece410
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / qshare-0.2.3-py3-none-win32.whl

Download URL qshare-0.2.3-py3-none-win32.whl
Size 18.5 MB
Tags Python 3 Windows x86-32
SHA-256 checksum
How to use checksums
e4566898048f33cfcc961f5441f29f205a0e789b5afe5e169fd04e1b419908f8
BLAKE2b-256 checksum
How to use checksums
63c439aa7c172b330386590196a72e0aa65c0b1c271a03bc70eed7b3ffbe1b89
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / qshare-0.2.3-py3-none-manylinux_2_17_armv7l.whl

Download URL qshare-0.2.3-py3-none-manylinux_2_17_armv7l.whl
Size 17.7 MB
Tags Linux glibc 2.17+ ARMv7l Python 3
SHA-256 checksum
How to use checksums
d937bd4777b9eb442a95694e67e5439ea91fa40b6d600a64c2617bb5748c6bd6
BLAKE2b-256 checksum
How to use checksums
e814c0112f9f74bbf00ce9cba43dd81f4df2bd15fb5a4db95c7e3553065c40ae
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / qshare-0.2.3-py3-none-manylinux2014_x86_64.whl

Download URL qshare-0.2.3-py3-none-manylinux2014_x86_64.whl
Size 19.2 MB
Tags Linux glibc 2.17+ x86-64 Python 3
SHA-256 checksum
How to use checksums
bc17791dc3eb59b00c1c6eeb0d9c4916626169cefc37595be283868d9fb69094
BLAKE2b-256 checksum
How to use checksums
54a06c4a594ae371f3f99927627c3c8bed9d24d93f6957d8ccd98f63a6f24010
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / qshare-0.2.3-py3-none-manylinux2014_i686.whl

Download URL qshare-0.2.3-py3-none-manylinux2014_i686.whl
Size 18.4 MB
Tags Linux glibc 2.17+ x86-32 Python 3
SHA-256 checksum
How to use checksums
7cf34f08ced1cdf1248faf7f123102a140c75a0697436a5e95b0f8df63e92ad8
BLAKE2b-256 checksum
How to use checksums
13bda82afc125f7e6ae0c240fb45311dfbd5d0c4ea5fd2f31297ac2aa2645d5d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / qshare-0.2.3-py3-none-manylinux2014_aarch64.whl

Download URL qshare-0.2.3-py3-none-manylinux2014_aarch64.whl
Size 17.7 MB
Tags Linux glibc 2.17+ ARM64 Python 3
SHA-256 checksum
How to use checksums
d703fe223811827aab3ede787ef78342adbe243c9fa36b769e2c6ccb7c933696
BLAKE2b-256 checksum
How to use checksums
6f017ec43ace32d5bc9ef9becad6198bbb286d2e0e38ea3feb9f3b36a18efc00
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / qshare-0.2.3-py3-none-macosx_11_0_arm64.whl

Download URL qshare-0.2.3-py3-none-macosx_11_0_arm64.whl
Size 19.2 MB
Tags Python 3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
84f2af6fad62688064da1889799b903689b89d00e33a7abc2dc11f99d94fe331
BLAKE2b-256 checksum
How to use checksums
934a5cc9a7833732a4111a62a9e045a3df6d3c7fa744ad919891137f3a965412
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / qshare-0.2.3-py3-none-macosx_10_13_x86_64.whl

Download URL qshare-0.2.3-py3-none-macosx_10_13_x86_64.whl
Size 21.1 MB
Tags Python 3 macOS 10.13+ x86-64
SHA-256 checksum
How to use checksums
c424e87f05a10667a68d35ca4406ff58d822caf47cf0b0160d30a42b0207601a
BLAKE2b-256 checksum
How to use checksums
2c64e7ac08d8a6b6cd3062a1f4247291b9fa77404bb82c7ee18fd70edb69a2f3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / qshare-0.2.3-py3-none-linux_armv6l.whl

Download URL qshare-0.2.3-py3-none-linux_armv6l.whl
Size 17.7 MB
Tags Python 3 linux armv6l
SHA-256 checksum
How to use checksums
17a98f4730b245ec4bf7d18029c207158b97ac9b72bf42ea6d944b46e6184b2f
BLAKE2b-256 checksum
How to use checksums
e8b1b1271b8bdb9c204a2b5198eb62abd2435af23f21a8fcb91e659e85c85632
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Security for qshare 0.2.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page