Giter Club home page Giter Club logo

klipper-cmd's Introduction

klipper-cmd

Project moved to Codeberg: https://codeberg.org/harveyk/klipper-cmd.

Bash script to transform and output clipboard content using KDE's Klipper.

Installation

Put the script klipper-cmd into /usr/local/bin.

For Klipper actions and commands see below.

Usage

klipper-cmd: Usage: klipper-cmd [OPTION] CMD [ARG]...

 Transform and output clipboard content (using KDE's Klipper) or ARG as indicated by CMD.
 
 Options:
  -h            Display this help and exit
  -v            Output version information and exit
 
 CMD:
  capitalize    Capitalize each word
  invertnames   Change "Firstname Lastname" to "Lastname, Firstname" and vice versa
  join          Join lines by replacing linebreaks with blanks
  join2         Like "join", but also remove trailing hyphens before joining lines
  lowercase     Transform content to lowercase
  print         Simply print the clipboard content (useful on command line only)
  underscores   Change all blanks to underscores and vice versa
  uppercase     Transform content to uppercase
  
 ARG:
  If present, work on ARG instead of current clipboard content.
  Use '%s' for current clipboard content when defining Klipper commands.

 This script may be run from the command line but is much more useful when called from Klipper actions, 
 see https://docs.kde.org/trunk5/en/kde-workspace/klipper/actions-page.html.
 
 To use this script with Klipper:
  Open the actions configuration page.
  Add an action with the following properties:
   Regular Expression: .*
   Description: Any content.
  Add one or more commands to this action like this (see CMD):
   Command: klipper-cmd capitalize '%s' 
   Output Handling: Add to Clipboard
   Description: Capitalize each word.

Credits

This script is based on https://esisteinfehleraufgetreten.wordpress.com/2011/08/31/textsnippets-bei-kde-mit-und-ohne-klipper/ and https://github.com/RenatGilmanov/shell-script-template/blob/master/getopts/template-commands.sh.

klipper-cmd's People

Contributors

hkramski avatar

Stargazers

 avatar

Watchers

 avatar

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.