Giter VIP home page Giter VIP logo

tty-copy's Introduction

tty-copy

Binaries Workflow Packaging status

A utility for copying content to the system clipboard from anywhere via a TTY and terminal using the ANSI OSC52 sequence. It works in any terminal session, whether local, remote (e.g. SSH), or even nested therein!

Refer to tty-copy(1) for usage information.

Supported Terminals

Here is a non-exhaustive list of the status of popular terminal emulators regarding OSC52 [1]:

Terminal OSC 52 support

Alacritty

yes

Contour

yes

far2l

yes

foot

yes

GNOME Terminal (and other VTE-based terminals)

not yet

iTerm2

yes

kitty

yes

Konsole

not yet

QTerminal

not yet

rxvt

yes (to be confirmed)

screen

yes

Terminal.app

no, but see workaround

tmux

yes

urxvt

yes (with a script, see here)

Windows Terminal

yes

Requirements

Runtime:
  • UNIX-like system

Build:
  • C compiler and linker supporting at least C99 (tested with clang and gcc)

  • GNU Make

  • Asciidoctor (for building man pages)

Installation

On Alpine Linux

Install package tty-copy from the Alpine’s community repository:

apk add tty-copy

On Arch Linux

Install package tty-copy from AUR:

yay -S tty-copy

Or use another AUR helper.

On Fedora

Install package tty-copy from the Fedora repositories (since Fedora 35):

dnf install tty-copy

Using Pre-Built Binary

🐧 Linux: [x86_64] [aarch64] [armv7] [ppc64le] [riscv64]
macOS: [x86_64]

  1. Download and verify tty-copy binary for your CPU architecture (pick the right link from the list above), for example:

    curl -sSLO https://github.com/jirutka/tty-copy/releases/download/v0.2.2/tty-copy.x86_64-linux
    curl -sSL https://github.com/jirutka/tty-copy/releases/download/v0.2.2/checksums.txt | sha256sum -c --ignore-missing
  2. Install tty-copy somewhere on your PATH, e.g. /usr/local/bin:

    install -m 755 tty-copy.* /usr/local/bin/tty-copy

All binaries are statically linked with musl libc, so they work on every Linux system (distro) regardless of used libc.

From Source Tarball

wget https://github.com/jirutka/tty-copy/archive/v0.2.2/tty-copy-0.2.2.tar.gz
tar -xzf tty-copy-0.2.2.tar.gz
cd tty-copy-0.2.2

make build
make install DESTDIR=/ prefix=/usr/local

Credits

This program is inspired from termcopy and vim-oscyank.

License

This project is licensed under MIT License. For the full text of the license, see the LICENSE file.


1. This list was originally copied from vim-oscyank.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.