New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
A script that might be of use #7
Comments
Hi @fjueic, I can see how this can be a useful alternative! Perhaps it could be packaged even nicer if you when you |
I just learnt about the #!/bin/sh
echo -n "Enter the path of your Obsidian vault: "
read vault_path
vault_path+="/.obsidian/plugins/obsidian-local-rest-api/main.js"
echo "46992a46993,47001
> scrollEditorPositionIntoView(req, res) {
> return __async(this, null, function* () {
> const { center, range } = req.body;
> const activeView = this.app.workspace.getActiveViewOfType(import_obsidian.MarkdownView);
> const editor = activeView.editor;
> editor.scrollIntoView(range, center);
> res.json();
> });
> }
47048a47058
> this.api.route(\"/editor/scroll-into-view\").post(this.scrollEditorPositionIntoView.bind(this));
" | patch $vault_path |
In case you want the file
|
thanks for the patch script, its really convenient. also @oflisback is obsidian_sync not intended to be a two way sync? for example in obsidian when i use "open weekly note" or open a file, i expect nvim to also open the corresponding file. |
welcome
same in my machine. i think you can somehow use |
I have added a reference to this issue from the README now as an alternative to building the fork, thanks for suggesting it. And @one2three4f, no obsidian-bridge is unfortunately one-way communication to control obsidian via network calls, I agree that ideally it would be a two-way sync, please share if you have ideas on how to accomplish it. |
Script to add scroll with buffer REST api
/editor/scroll-into-view
without buildingAdding to Readme as a possible way might help others. But I would totally understand if you outright reject this idea.
I clone the Original REST api repo manually added the changes from Your fork
used
diff
to compare bothmain.js
files and created a script to add the changes to the original file.Why script?
In case of update of the original extension, I can just run the script again to add the changes.
I am still a newbie in neovim, I wonder if there is a way to conditionally add the changes to the original file using
obsidian-bridge.nvim
plugin.The text was updated successfully, but these errors were encountered: