Clipboard Copy Commands
A set of functions to simplify copying to the clipboard in the terminal.
Clipboard Copy Commands
A set of functions to simplify copying to the clipboard in the terminal.
This file adds copy
and copypwd
functions to your Fish shell. It's designed for fast CLI clipboard workflows and includes a smart help menu with colorized output.
Ensure xclip
is installed, as it's required for copying to your system clipboard.
Installation
Place the script in your shell config directory (e.g., ~/.config/fish/functions/clipboard
) and source it from your main config:
It will remain silent when sourced.
Usage
🧪 Copy current working directory
📋 Will copy: /current/path/you/are/in
🧪 Copy a full path to a file
📋 Will copy: /full/path/to/myfile.ts
🧪 Copy a file's contents
📋 If the file contains "hello world", this string will be copied to the clipboard.
🧪 Show the colorized help menu
Any of the following commands will show the help menu:
⏹️ Recognized aliases: copy
, copy -h
, copy --h
, copy help
, copy -help
, copy --help