git-smart-checkoutLink to extension in marketplace https://marketplace.visualstudio.com/items?itemName=vradchuk.git-smart-checkout Info
Comments and contributions are very welcome! MotivationIn fast-paced development environments, switching between Git branches is a frequent but often disruptive task. Developers may have uncommitted changes that block a checkout, leading to tedious manual stashing and the risk of losing or misplacing changes. This common friction interrupts focus, breaks workflow, and slows down productivity. The Our goal is simple: make Git smarter, so you don’t have to think about it. Checkout modesAuto stash in current branchThis mode is useful if you need to keep stash with your branch.
In this mode, extension creates a automatic stash for the current branch (let's call it Auto stash and pop in new branchThis mode is helpful if you need to transfer your changes to a new branch after checkout. In this mode, extension creates a stash from working directory, switches to a new branch and then pop the stash. Auto stash and apply in new branchThis mode is helpful if you need to transfer your changes to a new branch after checkout but want to keep the changes with original branch where changes were originally made. In this mode, extension creates a stash from working directory, switches to a new branch and then apply the stash, e.g. add stashed changes but does not remove them from stash stack.
No auto stashThis mode is just ordinary checkout without any auto stash functionality. Pull with stashThe extension provides a convenient Pull with stash feature. When you run this command, your uncommitted changes are automatically stashed before pulling updates from the remote branch. After the pull completes, your changes are restored. This ensures a smooth workflow and prevents conflicts or loss of local changes during a pull operation. |