Pular para o conteúdo

copy - copiar para a área de transferência

Copia para a área de trabalho (clipboard) os parâmetros enviados ao script ou os lê via STDIN.

Exemplos:

./copy string
./copy <ENTER> this is a string <^d>
./copy < string
./copy < filepath
Perfil removido removido
Hits: 5.054 Categoria: Shell Script Subcategoria: Miscelânea
  • Download
  • Nova versão
  • Indicar
  • Denunciar

Descrição

Copia para a área de trabalho (clipboard) os parâmetros enviados ao script ou os lê via STDIN.

Exemplos:

./copy string
./copy <ENTER> this is a string <^d>
./copy < string
./copy < filepath
Download copy Enviar nova versão

Esconder código-fonte

#!/bin/sh
#
# if no args are given it reads stdin for input
# redirection can be used to read from another process or via pipe
# there is no need to quote as it takes all args
#
# examples:
# copy string
# copy <Return>, this is a string <^d>
# copy < string
# copy < filepath
#
# depends: xsel

if test -n "$1"; then
  printf "%s" "$*" | xsel -bi
  exit $?
fi

printf "%s" "$(cat)" | xsel -bi

Gerenciador Servidor de Arquivos

ZPenBoot - Gravando imagem ISO em um pendrive

tagtool

Usando Shell para incluir múltiplos usuários no Windows

GoogleChromeUpdate.sh para Slackware

Nenhum comentário foi encontrado.

Contribuir com comentário

Entre na sua conta para comentar.