wiki/docs/git/Команды.md
ilyamak04 12b4c91358
All checks were successful
Build MkDocs / build-and-deploy (push) Successful in 13s
git pull --rebase
2025-02-08 14:25:30 +03:00

18 lines
1.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

### Полезные источники
- [**Стетейки по гиту**](https://kb.tishenko.dev/git/aliases/)
- [**GitHowTo**](https://githowto.com/ru)
- [**GitFlow**](https://habr.com/ru/articles/106912/)
- [**Игра**](https://learngitbranching.js.org/?locale=ru_RU)
### Команды
- `git remote -v` - показывает все удалённые репозитории, которые связаны с локальным репозиторием
- `git init ; git remote add origin <https> or <ssh>` - добавить удалённый репозиторий
- `rm -rf /path/to/repo/.git` - git больше не будет отслеживать эту директорию
- `git config --global --list`
- `git config --global user.name "Ваше Имя"`
- `git config --global user.email "ваш_емейл@example.com"`
- `git config ...` - изменить для конкретного репозитория (без флага `--global`)
- `log --pretty=format:'%h %cd | %s%d [%an]' --graph --date=iso` - удобный вывод `git log`
- `git pull --rebase` - спуллить изменения из удалённого репозитория в локальную ветку не создавая мерджи, локальные коммиты просто встанут после коммитов из удалённого репозитория