You are not logged in.
Pages: 1
Topic closed
I'm trying to make a python script that will take a screenshot using scrot, upload it to imageshack.us and then copy the image link to the clipboard (parcellite).
The problem lies in the "copy to the clipboard" part. The documentation states that the command "parcellite string" will copy "string" to the clipboard, but it does not happend.
$parcellite string
$parcellite -o
last thing copied, not "string"
Also, a bunch of
Xlib: extension "Generic Event Extension" missing on display ":0.0".
warnings hit me each time parcellite is called, but I think they are harmless.
[SOLUTION]
Using "echo string | xsel -i -b" instead of "parcellite string".
Last edited by BoppreH (2009-02-21 00:57:24)
Offline
maybe try parcellite "string" or echo "string" | parcellite? i don't know i've never used it.
as for the Xlib errors, they are indeed harmless but they mess up some scripts i have that expect output but use the error instead, adding 2>/dev/null to the offending command fixes this.
//github/
Offline
maybe try parcellite "string" or echo "string" | parcellite? i don't know i've never used it.
as for the Xlib errors, they are indeed harmless but they mess up some scripts i have that expect output but use the error instead, adding 2>/dev/null to the offending command fixes this.
Those two were the first thing I tried, since it's in the man. But they don't work.
Offline
Is there a parcellite process after you use the command? (or the daemon?)
Offline
Is there a parcellite process after you use the command? (or the daemon?)
It is already open, starting by default (openbox autostart).
But when it's not, the command just executes and quits silently. No process is left.
Offline
I mean any result from pgrep parcel?
X11 needs the it to be alive or the clipboard is erased. In xsel e.g.
$ echo test | xsel -i -b
$ xsel -o -b
test
$ pgrep xsel
4567
$ pkill xsel
$ xsel -o -b
(nothing)
Although it seems nothing was ever copied in your case, because the previous contents are still there
Offline
I mean any result from pgrep parcel?
X11 needs the it to be alive or the clipboard is erased. In xsel e.g.
$ echo test | xsel -i -b
$ xsel -o -b
test
$ pgrep xsel
4567
$ pkill xsel
$ xsel -o -b
(nothing)Although it seems nothing was ever copied in your case, because the previous contents are still there
I looked for "pgrep parcel" in google and this page was the first result. *facepalm*
But no, no results.
I don't have xsel installed, so those tests are not valid. But after installing it, the output is exactly the same.
But "echo string | xsel -i -b" does the trick, without parcellite. Thank you.
Last edited by BoppreH (2009-02-21 00:56:35)
Offline
Using "echo string | xsel -i -b" instead of "parcellite string".
Thanks,it works well
Offline
This thread is rather old ...
Offline
@maonx, I'm glad you found the content of this thread helpful, but we discourage necrobumping old threads as well as empty posts.
http://wiki.archlinux.org/index.php/For … Bumping.27
http://wiki.archlinux.org/index.php/For … mpty_Posts
Closing.
Offline
Pages: 1
Topic closed