#!/usr/bin/env perl# Copy PRIMARY selections to the clipboard too with xsel(1).usestrict;usewarnings;subon_start{my($self)=@_;$self->enable(sel_grab=>\&clip);return;}subclip{my($self)=@_;if(openCLIPBOARD,'| xsel -ib'){printCLIPBOARD$self->selection();closeCLIPBOARD;}return;}