Back to Home

Vimperator + Goo.gl = convenient URL shortener without unnecessary gestures

firefox · vimperator · goo.gl

Vimperator + Goo.gl = convenient URL shortener without unnecessary gestures

    Like most netizens, I sometimes have to use URL shorteners. But every time I don’t want to go to the site of the abbreviation, and even more so to add unnecessary add-ons in Firefox. All sorts of bookmarklets don't suit me, because they don’t copy the shortened URL to the clipboard, but either translate shortcuts to the website or display a dialog box in which the shortened URL. I wanted the URL to be automatically copied to the clipboard, and the method itself could be conveniently used without a mouse.

    Because I use Vimperator , the choice naturally fell on him. Having visited the site and searched for plugins by topic, I did not find anything. But then I found a good plugin " tr.im script ", which was quickly redone for Goo.gl :)
    The aforementioned plug-in and the article from the habr " We use Goo.gl without the Google Toolbar ", or rather a piece of code from the bookmarklet in it:
    http://ggl-shortener.appspot.com/?url= "+ encodeURIComponent (window.location.href)
    
    Having conjured a bit with javascript code, which I almost do not know, I got the finished result.

    How to install
    We take the plug-in itself , copy it to the ~ / .vimperator / plugin / directory (or% HOME% \ vimperator \ plugin for Windows) and restart Firefox or run the command in it (sometimes it doesn’t help):
    : loadplugins
    

    How to use
    Enter
    : gg
    and press Enter. The abbreviated url will be on the clipboard, and the message vimperator'a will appear on the command line
    Yanked short_url
    
    (of course, instead of short_url there will be a shortened url;)).

    Read Next