D
D
Demigodd2020-03-05 19:45:32
git
Demigodd, 2020-03-05 19:45:32

How to correctly save local changes in GIT?

If I have a modified file then I just run the command.

git diff changet-file.txt > new-diff-file

And if in the future I need these changes, then git apply new-diff-fileto help.

But this method does not work with folders, and if there are a lot of files, you can simply get confused in them.

What methods or tools are there to effectively save local changes and then control them?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Andrey, 2020-03-05
@Demigodd

git checkout -b my_local_branch
git add .
git commit -m 'stub #100500'
git checkout master

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question