-
-
Notifications
You must be signed in to change notification settings - Fork 72
Description
Discussed in #546
Originally posted by slalik March 11, 2024
I think it would be useful to call vim with some options depending on the site. For example, on a webmail it could be vim -c "set filetype=mail textwidth=72 spell", on a forum vim -c "set filetype=bbcode spell" and so on.
Is it possible to do this?
I can imagine an external approach, for example, to have a script that first read the title of the active window (say, xdotool getactivewindow getwindowname) and then call vim with needed options.
But I think it would be better to be able to do this using Vieb, for example, Vieb could add the domain to the filename, something like <unique random string>.example.org (this is how it works in the "Browser's external editor" Chrome extension)
Probably best to do in the form of a filename setting for this edit action that supports templating.