git reset –hard not work

Time:2020-10-26

When using git to switch branches, you will be prompted that I have local changes. Prepare to reset, and then switch branches

git reset --hard
git status

But it didn’t get the desired results:

git reset --hard not work

It’s strange that the file is still prompted to be modifiedreset --hardThe original is not to retain file changes to restore

Google searched: unstated changes left after git reset — hard – stack overflow

Say yes and.gitattributesThe file is related, so according to the instructions, first delete and then reset:

git reset --hard not work

Here as a record

Recommended Today

Layout of angular material (2): layout container

Layout container Layout and container Using thelayoutDirective to specify the layout direction for its child elements: arrange horizontally(layout=”row”)Or vertically(layout=”column”)。 Note that if thelayoutInstruction has no value, thenrowIs the default layout direction. row: items arranged horizontally.max-height = 100%andmax-widthIs the width of the item in the container. column: items arranged vertically.max-width = 100%andmax-heightIs the height of the […]