Skip to content

Conversation

@PekingSpades
Copy link

Related Issue

Fixes #85

Changes

  • Linux: return the stored Init error immediately in clipboard.Write (and related paths) instead of waiting for the 5-second timeout.
  • Linux: when loading X11, try libx11.so.6 as a fallback if libX11.so is missing so systems without the unversioned symlink stay supported.

Testing

  • GOOS=linux GOARCH=amd64 go test ./...
  • Run gclip -copy foo with DISPLAY unset: now fails fast with the Init error.
  • Run gclip inside a container that only provides libx11.so.6: succeeds after picking up the fallback.

Notes

  • No changes to macOS/Windows/iOS/Android code paths.
  • Additional versioned fallbacks can be added later if other environments require them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Linux write waits 5s after Init failure and lacks libx11 fallback

1 participant