87
votes

Is there a menu option or keyboard shortcut to collapse all expanded folders in the sidebar? It gets messy over there and seems like there should be a better way than closing them one by one.

3

3 Answers

160
votes

On OSX: option + left click at the root node.

On windows/linux: control + alt + left click

20
votes

For Sublime Text 3 on Linux Mint 17.2 w/ Cinnamon I had to disable the following setting:

System Settings->Windows->Behavior->Moving and Resizing Windows->Special key to move and resize windows

After that Alt+left click worked!

-1
votes

using purely keyboard, on a mac, to unfold

CMD + K + 0

to fold, depending on the level of indentation

CMD + K + {level of indentation number} (eg. CMD + K + 2)

Refer here for more details functions of sublime text. Found this really helpful