Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding -s for -selection and setting changing the default selection #149

Open
erikd234 opened this issue Jan 20, 2024 · 2 comments
Open

Comments

@erikd234
Copy link

Hey! I love xclip and I use it everyday.

I am just getting tired of typing -selection clipboard each time cause thats my main usecase.

I would like to contribute to the project by adding

-s as a shortbut for -selection

and also I would like to add a way to change the default option for selection from primary to clipboard (or any other option if someone wants it.)

Can I go ahead and try to add the implimenation to the source code?

thanks.

TLDR:
add for example:

xclip -s clipboard -i < file.txt
xclip -selection-default clipboard
Thus allowing:
xclip -i < file.txt
(automatically going to the default option)

Then I guess also adding these options to the -help and man entries.
I would like to try and impliment them myself. It would be my first open source contribution :)

@erikd234
Copy link
Author

Update on this is that

-sel exists and I ddint know it becasue its not in the print help

I will make a PR to add it to -help and also add -s to do selection

I also found out through reading the code that -sel c and -sel s work to shorten the selection so that is totally fine no need for seting a default.

@erikd234
Copy link
Author

erikd234 commented Jan 20, 2024

#150

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

No branches or pull requests

1 participant