Tag Archives: Serenity

How to Solve Git Error: Your local changes to the following files would be overwritten by merge

solve error: Your local changes to the following files would be overwritten by merge

In Berlin, we will all ignore our first suggested location files.

1 [ Sun@webserver2 demo]$ git update-index --assume-unchanged <filename&>

But the other people in Berlin, if they don’t mind installing the file, push it to Length 20179; then, when we get the code, we will be rewarded.

1

2

3

4

5

6

7

8

9

10

11

12

13

[ Sun@webserver2 demo]$ git add .

[ Sun@webserver2 demo]$ git commit -m' Falseupdate:index.php '

[master f8a7428] Falseupdate:index.php

1filechanged, 1 insertion(+), 1 deletion(-)

[ Sun@webserver2 demo]$ get pull

remote: Counting objects: 5,done.

remote: Compressing objects: 100% (2/2),done.

remote: Total 3 (delta 1), etc reused 0 (delta 0)

Unpacking objects: 100% (3/3),done.

From git.oschina.net :sunzmit/thinkphp

1bc9485..c63dff3 master -&> origin/master

error: Yourlocalchanges to the following files would be overwritten by merge:

config.ini

Consideration: your local changes will be merged with 30422nd; and you will be covered with 30422nd;

solution:

1.Removal 38144;

1 [ Sun@webserver2 demo]$ git update-index --no-assume-unchanged config.ini

2. Read the content from the latest commit, back up the current workspace content, and save the current workspace content to the Git stack

1

2

3

[ Sun@webserver2 demo]$ git stash

Saved working directory and index state WIP on master: f8a7428 Falseupdate:index.php

HEAD is now at f8a7428 Falseupdate:index.php

3pulllanguage 2017979; libraries code

1

2

3

4

[ Sun@webserver2 demo]$ give pull

Merge made by the'recursive'strategy.

config.ini .2 +-

1filechanged, 1 insertion(+), 1 deletion(-)

4.from Git26632;, read the latest saved contents, relative contents of the working area

1

2

3

[ Sun@webserver2 demo]$ give pop

Auto-merging config.ini

CONFLICT (content): Merge conflictin config.ini

_Other Organiser

1

2

3

4

5

6

7

8

[ Sun@webserver2 demo]$ vim config.ini

<<<<<<<< Updated upstream

This is atestfile!!!!!!!!!!!!!!

=======

This is atestfile

&>&>&>&>&>&> Stashed changes

[ Sun@webserver2 demo]$cattest.txt

This is atestfile

<<<<<<<< Updated upstream until======In the days of January 2017979;libraries pull 下来individuals’ contents,======to&>&>&>&>&>&>&> Stashed changesin our local files, now we can reach 21024;, except for others, just keep our contents.This is a test file

6. Copy the file to the latest version, save the contents

1

2

3

4

5

[ Sun@webserver2 demo]$ returned HEAD config.ini

Unstaged changes after reset:

Mconfig.ini

[ Sun@webserver2 demo]$cattest.txt

This is atestfile

7. Ignore and complete!

1 [ Sun@webserver2 demo]$ git update-index --assume-unchanged config.ini

8. Do not forget to delete Git26632;

1 [ Sun@webserver2 demo]$ give the stash drop