Tell me what keys to hold, but it's hard to add all the files I need to git with handles.
1 answer
Add files to individual directories:
It was:
$ git status # On branch master # Changes not staged for commit: # (use "git add <file>..." to update what will be committed) # (use "git checkout -- <file>..." to discard changes in working directory) # # modified: calc/index.php # modified: include/configs/keys.php # no changes added to commit (use "git add" and/or "git commit -a") Executed the command:
$ git add calc/ It became:
$ git status # On branch master # Changes to be committed: # (use "git reset HEAD <file>..." to unstage) # # modified: calc/index.php # # Changes not staged for commit: # (use "git add <file>..." to update what will be committed) # (use "git checkout -- <file>..." to discard changes in working directory) # # modified: include/configs/keys.php # $ You can also use the * sign to indicate part of the file name, and so on.
You can also add all the files in a crowd, and then eliminate ( unstage ) unnecessary ones, if you see that excluding fewer files than adding.
It was:
$ git status # On branch master # Changes to be committed: # (use "git reset HEAD <file>..." to unstage) # # modified: calc/index.php # modified: include/configs/keys.php # Executed the command:
$ git reset calc/ Unstaged changes after reset: M calc/index.php It became:
$ git status # On branch master # Changes to be committed: # (use "git reset HEAD <file>..." to unstage) # # modified: include/configs/keys.php # # Changes not staged for commit: # (use "git add <file>..." to update what will be committed) # (use "git checkout -- <file>..." to discard changes in working directory) # # modified: calc/index.php # $ |
все нужные мне файлы в гит добавлять- and why not add files with the-Akey? Like this:git add -A, or add to the catalog, indicating the path - AK ♦git status. so I clarify. - aleksandr barakin