Skip to main content

Share files from the terminal of your computer to a smartphone by scanning a QR code.

Project description

share-file-qr

PyPI

Share files from the terminal of your computer to a smartphone by scanning a QR code.

This repo is a Python re-implementation of the original Go version by Claudio d'Angelis.

Installation

This program requires Python 3.9 or later.

Installation:

  • pipx install share-file-qr
    • find install instructions for pipx on their website

Principle

The principle is the same as in the Go version:

  1. you give a file to the tool in your computer's terminal
  2. the tool serves this file with an HTTP server
  3. the tool gives you a QR code leading to the URL. This URL points to the server and the file on the local network.
  4. you scan the QR code with your smartphone and get the URL to your file
  5. you open the URL with your smartphone's web browser, and download starts
  6. once download finishes on your smartphone, you stop the tool in your terminal

Usage

First, make sure your computer and your smartphone are connected to the same local network. This is in general the case if they are connected to the same router in your home. If you have doubts, check their IP addresses. Please also be aware that this tool does not work with IPv6.

Once connectivity issues are solved, run the tool by providing a file:

screenshot

At this point, you should have a QR code displayed directly in your terminal, or in your computer's browser as an SVG image.

Once you have a QR code (either directly from the terminal or from your computer's browser) scan it with your smartphone to get a URL to the file and download it in your web browser. Depending on your phone's OS you may have to scan the QR code differently:

Development notes

License

GPLv3

Authors

This Python tool was implemented by Pierre Walch, based on ideas from a Go project by Claudio d'Angelis.

Instructions for publishing to PyPI

  • enter the venv of the project
  • python setup.py sdist
  • test: twine upload -r testpypi dist/*
  • real: twine upload dist/*

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

share-file-qr-0.2.0.tar.gz (17.7 kB view details)

Uploaded Source

File details

Details for the file share-file-qr-0.2.0.tar.gz.

File metadata

  • Download URL: share-file-qr-0.2.0.tar.gz
  • Upload date:
  • Size: 17.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.1

File hashes

Hashes for share-file-qr-0.2.0.tar.gz
Algorithm Hash digest
SHA256 3887499e3ac2529e1ed191f5e671e500a474de7c41b4e50e9dc5da260a6789ed
MD5 ddca8911cef69460fb16f9933b76ca2a
BLAKE2b-256 da3496c4ad21ebb0ad880ad25830bd7cd83725a399fdaa41057bb7cdb7dcae5a

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page