11 rustPlatform.buildRustPackage rec {
15 src = fetchFromGitHub {
19 hash = "sha256-MqA/ELIX16H7dDPZkg9OmNO/df7Bui3an1CSj5kGWwM=";
22 cargoHash = "sha256-3KcXa4c4X9L9AeK64vD0DJY/kMS4qzWN+s6YEOF1xrQ=";
24 buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [
25 darwin.apple_sdk.frameworks.Cocoa
26 darwin.apple_sdk.frameworks.Security
27 darwin.apple_sdk.frameworks.SystemConfiguration
36 # Some test cases interact with X11, skip them
37 "--skip=test_x11_clipboard"
38 "--skip=test_x11_primary"
41 postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
42 for cmd in clipcatd clipcatctl clipcat-menu clipcat-notify; do
43 installShellCompletion --cmd $cmd \
44 --bash <($out/bin/$cmd completions bash) \
45 --fish <($out/bin/$cmd completions fish) \
46 --zsh <($out/bin/$cmd completions zsh)
51 description = "Clipboard Manager written in Rust Programming Language";
52 homepage = "https://github.com/xrelkd/clipcat";
53 license = lib.licenses.gpl3Only;
54 platforms = lib.platforms.linux ++ lib.platforms.darwin;
55 maintainers = with lib.maintainers; [
59 mainProgram = "clipcatd";