mindgre.blogg.se

Quick text paste
Quick text paste












quick text paste

At last, set a shortcut on newly created script.

  • Next you would need to save the content of the exampled script to a file and make it executable.
  • Pass saved and escaped variable as an argument to a browser and make sure that it pops up maximized in-front of other open programs by passing -window -maximize to a command line.
  • Make sure to really show the browser window (in my case Google Chrome) and not to run in background, by using xdotool.
  • Save your present clipboard data to CLIPBOARD variable, by running xsel -clipboard.
  • usr/bin/google-chrome "$" -window -maximize usr/bin/xdotool search -name "Google Chrome" windowactivate What we need, is a small utility called xsel and few lines in BASH script. It will help you to open a browser, paste text from your clipboard to Google Search - all with one little script, that can be and must be attached to a keyboard shortcut. The solution happen to be very easy and straight forward.














    Quick text paste