
From Vimperator to Tridactyl (2018) - stargrave
https://nullprogram.com/blog/2018/09/20/
======
0x445442
If only we had a plugin/extension called Meta-x. When the user typed the
Meta-x key combination a mini-buffer would be presented at the bottom of the
browser and the user could then run any command they wanted.

This plugin could ship with an initial set of commands like show-bookmarks,
search-page, etc.. The plugin would also provide a facility for easily adding
commands written in JS and installing 3rd party commands.

The user community could also share their custom commands in a central
location.

I guess the big question would be, does it make more sense to add this plugin
to Firefox, upgrade Conkeror to not require XUL or add Gecko to Emacs.

~~~
bovine3dom
What's the difference between this and Tridactyl? Completeness of commands?
The central location?

Otherwise it will do 90% of what you're asking.

~~~
0x445442
I can't speak to Tridactyl but some time back I looked at extending one of the
other plugins, can't remember if it was Vimperator or Pentadactyl, but when I
looked at adding my own custom scripts for extension it failed the 10 minute
rule so I moved on. Perhaps the ecosystem and/or documentation has been
enhanced with Tridactyl.

But you're right, there's really no difference between typing Meta-x and
colon; It's the same concept.

~~~
bovine3dom
You can rebind it to Meta-x, too.

The documentation last time I checked was roughly novella length, and it could
definitely do with some work. You currently can't escape line breaks in our
scripts which limits their complexity.

If you install Tridactyl, the `:tutorial` is the best place to start. Maybe we
should add a page on adding your own commands.

------
bovine3dom
I should probably use this bully pulpit to let Tridactyl users know that they
might be stuck on an old version of Tridactyl [1]. Check the hamburger menu in
the top right for a small yellow exclamation mark, click it and decide whether
to give us more permissions.

The extra permission is just so we can include a new (unbound by default) find
mode that uses a Mozilla API.

[1] [https://addons.mozilla.org/en-US/firefox/addon/tridactyl-
vim...](https://addons.mozilla.org/en-US/firefox/addon/tridactyl-
vim/statistics/usage/versions/)

------
nextos
I loved Vimperator and switched to Tridactyl as soon as Firefox forced me to.

It's great, but I am currently missing 2 features. First, in Vimperator you
could tab complete URLs with the open command _and_ then edit the URL. Second,
you could build lots useful commands with Vimperator. I had one for flipping
the proxy to a SOCKS one, and another command to do site-specific searches
with tab completion. That is, type s, write and/or tab complete a URL and type
the search. I would then submit a query to Google with the appropriate
site:url operator.

Are any of these possible in Tridactyl right now? I haven't been able to
reproduce any.

It's also annoying that lots of special Firefox pages, like unable to connect,
steal the focus from Tridactyl and you need to use actual shortcuts from
Firefox to find your way out. It kind of breaks the flow, but I understand
this is a limitation imposed by Firefox with their new plugin architecture.

~~~
bovine3dom
For editing a URL - press space to fill the command line with a highlighted
completion.

Custom commands are possible with `alias`, `js -p`, and `composite`. All are
documented with `help [command]`, but there's probably room for improvement.

We haven't bothered to integrate proxy controls but I think it's possible. No-
one has asked.

~~~
Legogris
I haven't been able to figure out how to do keymaps with fixed arguments for
commands. What I specifically want to do is to have something like f/F (open
hinted URLs) and/or t/T for opening URLs in specific containers. A lot of
times when I open a link I have a couple of containers that I often want to
open the link in.

~~~
bovine3dom
You probably want `bind t fillcmdline tabopen -c [mycontainer]`, and `bind F
hint -W tabopen -c [mycontainer]`, with hopefully obvious equivalents for T
and f. You can always do `bind [key-sequence]` with no argument to find out
what something is bound to.

~~~
Legogris
Thanks, going to try this :)

------
binaryapparatus
I first heard of Tridactyl because it was listed on
[https://suckless.org/rocks/](https://suckless.org/rocks/) page. It filled
huge gap left from Vimperator and no complaints on my side. Works well.

------
deadghost
I'm a cranky old man. I'm still on FF52 and pentadactyl. Tridactyl is still
missing a modeline and has janky smooth scroll.

~~~
alextooter
I am using Waterfox,it can use all XUL extensions,and keep update with latest
security fixes.

I love Firefox because all its old extensions,can't living without those great
things.

------
anotheryou
Has anyone figured out how to pass multiple arguments to js?

I want ":pocket my-tag" to trigger a bookmarklet with current url and the tag,
but I think the piping only ever passes 1 parameter. I guess JS_VAR could be
an array(?), but I wouldn't know how to fill it.

I guess I could just use one optional tag and get the url myself in js
(window.location.href).

This worked in pentadactyl (also this is a functioning, non documented
bookmarklet for pocket :) ):

    
    
        function(){window.open('https://getpocket.com/edit?url='+escape(window.location.href)+'&tags=<args>', '_self');}

~~~
bovine3dom
JS_ARG is a string. If you want an array, just split it on space or some other
character of your choosing.

E.g, `:alias only_first js -p window.alert(JS_ARG.split('|')[0])` `:only_first
this bit | not this`.

NB: untested, posted from 'phone.

------
180wdock
Tridactyl has something missing from a lot of its competitor extensions
(latest generation vimperator remakes): a native component that allows you to
run native commands, such as running mpv or youtube-dl on a hint-selected url.

------
skratlo
So it says that Tridactyl is built on WebExtensions API, which is kind of W3C
draft, which is kind of supported by Chrome. So.... Can Tridactyl be built for
Chrome?

~~~
bovine3dom
We use some Firefox-only APIs, but it's totally possible to port most of it,
if anyone cares. You'd need to use a polyfill, and have more graceful
fallbacks for the missing APIs - opening tabs is an obvious problem area as we
(can) use Firefox containers.

------
softinio
Timing of this article is perfect in the sense that I am in the market for
such a plugin. Has anyone tried this? Good? Anything better? Thanks!

~~~
quickpost
I use vimium on Chrome. Love it - can barely use a browser without it these
days. It's worth using alone just for the ability to easily click links
without ever touching the mouse.

~~~
eager_noob
fwiw one can use the '(single quote character) in firefox to easily find and
visit links without using the mouse. Quite handy and available out of the box

[https://blog.mozilla.org/theden/2012/12/20/quick_find/](https://blog.mozilla.org/theden/2012/12/20/quick_find/)

------
quickpost
> Edit any text input using a real text editor

Does anyone know if you can do something similar in vimium on Chrome? That
sounds absolutely awesome.

~~~
bovine3dom
E.g,
[https://chrome.google.com/webstore/detail/ghosttext/godiecgf...](https://chrome.google.com/webstore/detail/ghosttext/godiecgffnchndlihlpaajjcplehddca)

(Edited to fix link)

~~~
quickpost
Awesome - thank you! That link didn't work for me, but this works:
[https://github.com/GhostText/GhostText](https://github.com/GhostText/GhostText)

------
dangom
Would anyone know how this compares to Vimium? I hadn't heard of Tridactyl
before. I was using Firemacs before WebExtensions.

