48

It is said in IDEA documentation

Select this check box to have IntelliJ IDEA bring the changes staged in the index to your working tree for examination and testing.

Can somebody please explain what does this mean?

1
  • 3
    --keep-index keeps staged changes and stashes un-tracked changes. Commented Jan 2, 2018 at 8:00

1 Answer 1

52

This determines if the stash is created with the git --keep-index flag.

From GIT docs:

If the --keep-index option is used, all changes already added to the index are left intact.

So in other words, any files you've added to git will also remain outside of the stash when you create it. Whereas normally newly added files would be removed after stashing. (See this question for a more indepth description of where the index is.)

Sign up to request clarification or add additional context in comments.

2 Comments

thus in the end your staged changes remain in your workspace and are saved into your stash
this is a good answer to review as well: "Checkout another branch when there are uncommitted changes on the current branch" : stackoverflow.com/a/22055552/401226

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.