obsidian-git icon indicating copy to clipboard operation
obsidian-git copied to clipboard

Branch views [Feature request]

Open mattw-webcv opened this issue 11 months ago • 2 comments

Hello, I'm new to github ecosystem so forgive errors and omissions.

I'd like to have a cli permitting switches between branches (for viewing and editing). Switching between branches auto reveals and hides folders+files according to the branch.

Suppose in my single obsidian vault, I have 3 areas I work with independantly.

Research projects Business frameworks Personal records

If I then superimpose git branches- Obsidian would auto hide/reveal folders+files 'research' 'business' and 'personal' depending on the branch I'm in.

Absent other relevant plugins or features; I'd like to request git extension fill this in, and also request an idea of the scale and difficulty of implementing- perhaps I'd be able to attempt it myself.

Thank you for your time,

mattw-webcv avatar Apr 02 '25 02:04 mattw-webcv

I don't quite understand your feature request. Could you share an example of an IDE like you said? What do you mean with hide/reveal folders? Like hiding them in the file explorer, although the file exist?

Vinzent03 avatar Apr 09 '25 18:04 Vinzent03

Hi Vinzent, apologies for the extremely delayed response- I've been fighting with one of my services.

Perhaps I included too much extraneous detail, and the IDE I use is Zed* (not yet available for windows). What I'm asking for is actually what I originally thought obsidian workspaces did- until I learned what workspaces is.

I'm hoping there's a way to auto-hide entire folders+files from the files sidebar view until I'm ready to deal with them. Using the git plugin seems like the easiest and most straightforward method.

But it really is as simple as it seems. In obsidian, I'd use git to choose what branch I'm working in. Then, obsidian files view would auto hide/reveal the corresponding folders+files+file contents. Then, as above- if I'm working in the research projects branch, obsidian would hide all my folders and files from 'business frameworks' and 'personal records'.

The alternative is simply having multiple obsidian vaults, but having multiple vaults would require me to constantly duplicate a bunch of my resources/bibliography links.

Thank you for your time

  • https://zed.dev/

mattw-webcv avatar Apr 18 '25 23:04 mattw-webcv

Okay thanks for your explanation, I know understand your suggested improvement. But I've decided to not implement that in this plugin, sorry. However, it is doable with another community plugin. It could work just fine with the actual branch management from this plugin and react to events to alter the file view.

Vinzent03 avatar Jul 24 '25 22:07 Vinzent03