tmux-helper-filetransfer
Transfer files to filesystem of host accessible via tmux.
Usage
In tmux.conf:
bind-key Q run-shell " \
/path/to/.venv/bin/python \
-m tmux_helper_filetransfer \
--pane-id '#{pane_id}' \
--tmux-exe /proc/#{pid}/exe \
--tmux-socket '#{socket_path}' \
--quiet \
/path/to/dotfiles"
This transfers /path/to/dotfiles to the current directory in the remote
shell. To take other actions (like cding to a specific directory before
transferring files), then run a shell script that executes the
helper inside.
Requirements
The target pane can be hosting a terminal on the local host or on a remote host (accessed via e.g. ssh).
The target pane's shell must be able to successfully execute
uudecode | gunzip -c - | tar xf -.
The target pane's shell must be in insert mode (not vi-command mode).
Limitations
Some or all of these may be possible to overcome.
- Currently the local file processing requires that the entire file be held in memory at the same time, plus extra when both the tar and compressed objects are in scope - we would need streaming for the tar creation the compression and uuencoding.
uuencodeexpands the compressed bytes at least 33%.- Tmux itself is not responsive while executing the subprocess. - we could run a background process instead of blocking.
- No progress indication - a periodic
display-messagewould be the first thing to try. - No ability to cancel an in-progress transfer - if spawning a background process then giving the cli the ability to communicate via e.g. unix socket could be a good way to go.
Releasing
python setup.py sdist
# for testing
twine upload --repository testpypi dist/*
twine upload --repository pypi dist/*
Metadata
Release files for tmux-helper-filetransfer 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| tmux-helper-filetransfer-0.1.0.tar.gz | 4.2 kB | Without provenance | Details for tmux-helper-filetransfer-0.1.0.tar.gz |
Release files / tmux-helper-filetransfer-0.1.0.tar.gz
| Download URL | tmux-helper-filetransfer-0.1.0.tar.gz |
|---|---|
| Size | 4.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0db0edddb9c711467fc3cab01e07e7a24e40be8a6d8b1a793b41041922546554
|
|
BLAKE2b-256 checksum How to use checksums |
162f26777e59b5d6c6fafe3645c1732d2c2f66a83a9d106c5a5720f5e1e034ce
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/3.6.6
|
Security for tmux-helper-filetransfer 0.1.0
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.