Fix main selection handling in keep pipe ($)
Fix main selection handling in keep pipe ($)

$kak_reg_hash will properly contain the current selection index when
executing the shell command, fixing its use.

Fixes #1503

mawww/kakoune,occivink/kakoune,casimir/kakoune,casimir/kakoune,jkonecny12/kakoune,Somasis/kakoune,occivink/kakoune,jjthrash/kakoune,mawww/kakoune,lenormf/kakoune,casimir/kakoune,danr/kakoune,danr/kakoune,alexherbo2/kakoune,jjthrash/kakoune,mawww/kakoune,jjthrash/kakoune,casimir/kakoune,jkonecny12/kakoune,danr/kakoune,lenormf/kakoune,lenormf/kakoune,alexherbo2/kakoune,lenormf/kakoune,jjthrash/kakoune,danr/kakoune,Somasis/kakoune,jkonecny12/kakoune,alexherbo2/kakoune,occivink/kakoune,Somasis/kakoune,Somasis/kakoune,mawww/kakoune,jkonecny12/kakoune,occivink/kakoune,alexherbo2/kakoune