# CHANGELOG ## 2.0.0 ### Major Changes * Requires Ruby 3.0 * `Clipboard.copy` and `.clear` now always return true instead of the pasted string ### New Features * Add experimental OSC52 implementation (only `Clipboard.copy`) * Linux-based `Clipboard.copy` methods now take a clipboard argument `clipboard:` to choose which clipboard to copy to (default is "all"). For example: `Clipboard.copy("data", clipboard: "primary")` copies only to primary clipboard * Linux-based `Clipboard.paste` methods use either the `clipboard:` keyword argument or the single positional argument for choosing the clipboard to paste from * Allow setting the clipboard implementation with snake-cased symbol/string: `Clipboard.implementation = :linux_wayland` ### Refactorings / Minor API Changes * Change `copy`, `paste`, and `clear` to always accept keyword arguments * All implementations are now based on `Clipboard::Implementation` * Move implementation detection to `utils.rb` * Be sure to pass a valid lowercase clipboard selection name (or `"all"`) when choosing clipboards, it will now raise an `ArgumentError` if the clipboard name is not supported by the implementation ### Other * Add more specs and run them on GitHub Actions CI ## 1.4.1 * Always use plaintext mimetype for wl-clipboard * Do not include newline when pasting from wl-clipboard * Internal: Let ClipboardLoadError inherit from StandardError, not Exception ## 1.4.0 * Add Wayland support via `wl-copy`, patch by @cramt * Only silence clipboard warnings when $VERBOSE is nil ## 1.3.6 * Fix Windows implementation (so it works on more recent Windows), patch by @P3t3rU5 ## 1.3.5 * Fix missing String#+@ method on Ruby <2.3, patch by @AaronC81 ## 1.3.4 * Don't break on Ruby 2.1, patch by @grosser ## 1.3.3 * Fix Cygwin implementation to work when File constant is loaded, fix by @ntachino ## 1.3.2 * Windows version actually mutates a string, fix by @scivola ## 1.3.1 * Prefer xsel over xclip, because it can handle more data * See here: https://github.com/janlelis/clipboard/pull/33/files#diff-80752ab4de37ec2dcf1dc85457e09d40R13 ## 1.3.0 ### Bug Fixes * Conditionally read or don't read the output stream of external commands, fixes #32 * Special thanks to @orange-kao for the bug report + PR ### New Features * Add a GTK based clipboard ### Internal changes * Use frozen string literals ## 1.2.1 * Add WSL to autoloaded constants ## 1.2.0 * Support WSL (Windows Subsystem for Linux) ## 1.1.2 * Linux: Replace calls to `which` with native check (thanks @woodruffw) ## 1.1.1 * Surpress 3rd party processes' STDERR, see #26 * Internal API changes to meet modified relaxed ruby style guidelines ## 1.1.0 * Remove support for 1.8 * Windows: Fix that the gem tries to convert encoding of pasted strings, leave this to user * Support Cygwin's clipboard ## 1.0.6 * Improve Linux xsel support #17 ## 1.0.5 * Windows 1.9 multibyte support ## 1.0.4 * Restore 1.8 Support ## 1.0.3 * Don't load current version from file (gh#15) ## 1.0.2 * Add missing require 'rbconfig' * File backend: File only accessible by owner * Small tweaks ## 1.0.1 * Fix permissions in packaged rubygem ## 1.0.0 * Add basic java clipboard support ## 0.9.9 * Allow Ocra packing ## 0.9.8 * Fix a Windows bug ## 0.9.6 / 0.9.7 * Support rubygems-test ("gem test clipboard" if rubygems-test is installed) ## 0.9.5 * Fallback to Clipboard::File, if no other clipboard is available * Also check for xsel if using linux implementation * Fix for jruby copying * You can directly use a specific implementation, e.g.: require 'clipboard/file' # gives you Clipboard::File ## < 0.9.4 See https://github.com/janlelis/clipboard/commits/0.9.4