Skip to content

Instantly share code, notes, and snippets.

☠️
Literally dead

Grim GrimTheReaper

☠️
Literally dead
  • Hiding in a panic room.
Block or report user

Report or block GrimTheReaper

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@GrimTheReaper
GrimTheReaper / Better XClip.sh
Last active Mar 17, 2018
Append to bashrc to add better copying
View Better XClip.sh
# A shortcut function that simplifies usage of xclip.
# - Accepts input from either stdin (pipe), or params.
# Taken from: http://madebynathan.com/2011/10/04/a-nicer-way-to-use-xclip/
# ------------------------------------------------
cb() {
local _scs_col="\e[0;32m"; local _wrn_col='\e[1;31m'; local _trn_col='\e[0;33m'
# Check that xclip is installed.
if ! type xclip > /dev/null 2>&1; then
echo -e "$_wrn_col""You must have the 'xclip' program installed.\e[0m"
# Check user is not root (root doesn't have access to user xorg server)
You can’t perform that action at this time.