denolehov / obsidian-git

Backup your Obsidian.md vault with git
MIT License
6.12k stars 251 forks source link

[Feature]: newest file feature #740

Open 3fok opened 1 week ago

3fok commented 1 week ago

I want to update the newest versions of some files to continue working on another PC (e.g., workspace.json, app.json, etc.). Can you add that feature? It should ignore local files and just get the newest files from GitHub.

I don't want to ignore these files because I want to keep the environment I'm working in and continue on another PC.

Vinzent03 commented 1 week ago

I can't follow you completely. You don't want to ignore the files completely, so you don't want to add them to .gitignore. But when there is a commit with a newer version of e.g. config files, you don't want to merge them or even have merge conflict, but just overwrite them with the new commit? The best way to accomplish this is probably, before pulling locally, to discard the changes via the Source Control View. So that these changes aren't commited locally and are overwritten by the new commit.

3fok commented 5 days ago

I want to continue working with the same state on another machine. For example, if I open a file on one computer, I want it to remain open when I switch to another computer. Is there any way to do that?

ridhozhr10 commented 4 days ago

I want to continue working with the same state on another machine. For example, if I open a file on one computer, I want it to remain open when I switch to another computer. Is there any way to do that?

It will be nice if we have this, for me to workaround for now i just use "Workspaces" core plugin and make a layout template before pushing latest commit to git remote. image image Screenshot from 2024-06-27 09-01-47 Screenshot from 2024-06-27 09-02-03