-
Notifications
You must be signed in to change notification settings - Fork 1
Not an editor command ":nHead" #1
Comments
I think this problem stems from Obsidian's code mirror version being updated, and causing the api used to create the commands to now be incorrect. If you are interesting in solving the issue, I'd most likely look at the Vimrc plugin and see how they changed things with registration of commands, and emulate the changes to this plugin. If not, I'll see if I can get to this some time soon :) |
Seems this is the crux of the changes needed: esm7/obsidian-vimrc-support@c7253f1#diff-564c860307257bfac9176f554a35aa858c350a59d75c0dcd0a5d63a480805bd0R76-R159 And then just a bunch of search and replace. |
Revisiting this, is it just me or do any features of this plugin currently work? Typing
Cheers for the |
When this plugin originally was released, commands worked well. However, at the moment, I don't use obsidian anymore, and I don't have enough time to fix this at the time being :(. Huyz has provided a nice reference that could be used to fixup this plugin. |
I guess I can take a crack at it |
I got most of it to work, but |
@huyz Thanks for giving it a good go with some improvements! Could they be merged in? |
I shouldn't say "most". I only got the |
The author of the vimrc-support-plugin has added a file with a tutorial on how to achieve this: https://github.com/esm7/obsidian-vimrc-support/blob/master/JsSnippets.md You need to
|
FYI I got around the annoying aspect of 1 by just putting it in my |
Now if someone could also write a |
I'm not really concerned about getting nmap j gj
nmap k gk
vmap j gj
vmap k gk
exmap 0 goLineLeftSmart
exmap $ goLineRight |
FWIW it looks like as of today, codemirror-vim now has nnoremap 0 g^
nnoremap $ g$
nnoremap H g^
nnoremap L g$
nnoremap I g^i
nnoremap A g$a (And |
It seems this plugin is mostly obsolete, I don't use Obsidian anymore and haven't for a long time. If you'd like to update the README with more info/context regarding this, it would be more than welcome :) |
Hey @hhhapz :) sure happy to update things here. I also did a little more digging and was able to get your plugin's implementation of So, your repo may not be obsolete, for that use case. But you don't need to maintain it if you don't want to anymore—we could either:
Let me know if you'd prefer either one, I'm happy with anything |
I'm happy with anything, if you'd like to fork, that's fine with me, if you want commit access here, I'll be happy to give you that too. |
Okay cool, it could be simpler to just bring the changes into here, then. Other than I'm not quite sure how the release process works with the official Obsidian plugin directory, but briefly looking into it, it looks like I can maybe just do that through GitHub. Can look more into that when I get a chance :) |
I'm perfectly good with adding these to obsidian-vimrc-support, if you wish. Whatever you think would be better :) |
@esm7 Oh nice, yeah if you're happy to do that, I think that'd be best from a user perspective too, just needing to install a single plugin :) |
Mind opening a pull request for that? It'll probably take me a couple of weeks to review, as I'll use the opportunity to also review other issues and release an updated version, but we can definitely get it done. |
Sure sounds good :) I'll work on writing that up |
Sorry for the delay here, got busy with some other stuff, but just put up a PR for obsidian-vimrc-support to provide these (and a couple other) motions/commands. If that looks good and gets merged, we can probably go ahead and deprecate this plugin |
I've got the
.obsidian.vimrc
lines:When I type
]]
, I see:This plugin is installed and enabled through Obsidian's settings. v0.0.1
How would I go about debugging this?
The text was updated successfully, but these errors were encountered: