denolehov / obsidian-git

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

[Bug]: "Pull updates on startup" also commits and pushes #736

Open Kageetai opened 2 weeks ago

Kageetai commented 2 weeks ago

Describe the bug

Hello,

first, many thanks for this plugin and the work. I would not be able to work without Git in Obsidian :)

One thing I noticed and has become a small nuisance from time to time, though: I have the option "Pull updates on startup" on, as I want to have my latest changes pulled every time. But what I don't necessarily want is to commit/push my latest local changes at the same time. But it seems this is not possible. Below, a screenshot of my current settings around that:

Screenshot 2024-06-12 at 10 40 30

From my understanding of these settings, this should only pull on startup, but not commit/push. But it does so anyway. Would it be possible to adjust that, maybe with a setting?!

Relevant errors (if available) from notifications or console (CTRL+SHIFT+I)

No response

Steps to reproduce

  1. Activate settings as shown above
  2. Restart or reload Obsidian
  3. All previously uncommitted files get committed automatically on startup

Expected Behavior

Addition context

No response

Operating system

macOS

Installation Method

None

Plugin version

2.24.2

Vinzent03 commented 2 weeks ago

Can you please share your other settings under the "Automatic" heading in the plugin settings?

Kageetai commented 2 weeks ago

Here a screenshot of the "Automatic" section:

Screenshot 2024-06-16 at 12 56 12

Vinzent03 commented 1 week ago

That's the expected behavior. Or, at least, if you haven't used Obsidian for 6 (360 min) hours. When the last edit is 6h ago, and you start Obsidian, it first pulls because of the "Pull on startup" setting and afterward creates a backup, because of your Auto backup settings.

Kageetai commented 1 week ago

Unfortunately, it's not just about the backup interval. It also happens if I just did a manual backup and then restart/refresh Obsidian. It then does another backup. Are there any other settings that can influence that?