Git Essentials: Must Know Commands #devops #git
Follow us on
Twitter: https://twitter.com/devopstricks
Instagram: https://www.instagram.com/devopstipsandtricks/
Youtube: https://www.youtube.com/@devops-tips-and-tricks
git init: Creates a new Git repository or converts an existing directory into a Git repository.
Example: git init my_project
git config: Displays or modifies Git configuration settings, such as username, email address, color preferences, etc.
Example:
git config --global user.name "John Doe"
git config --global user.email "[email protected]"
Basic Commands:
git add: Adds changes from the working directory to the staging area.
Example: git add file.txt or git add . (adds all changes).
git commit: Records changes from the staging area as a "commit".
Example: git commit -m "Added new feature"
Status and History-Related Commands:
git status: Shows the status of changes and the staging area.
Example: git status
git log: Lists the commit history.
Example: git log --oneline
git diff: Shows the differences between the working directory and the staging area or HEAD.
Example: git diff file.txt
Commands Related to Remote Server:
git remote: Lists or adds remote servers.
Example: git remote add origin https://github.com/user/repo.git
git push: Sends local changes to a remote server.
Example: git push origin master
git pull: Fetches and merges changes from a remote server to the local repository.
Example: git pull origin master
Branching and Merging Commands:
git branch: Lists all branches or creates a new branch.
Example:
git branch (lists branches)
git branch new_feature (creates a new_feature branch)
git checkout: Switches to another branch as the current working area.
Example: git checkout new_feature
git merge: Merges two branches.
Example:
First, be on the target branch: git checkout main
Then merge the source branch: git merge new_feature
Other Commands:
git clone: Copies a remote repository to a local machine.
Example: git clone https://github.com/user/repo.git
git rm: Removes files from the Git repository and updates the working directory.
Example: git rm obsolete_file.txt
#devops #git #kubernetes #k8s #devopstutorial #kubernetesforbeginners
Что делает видео по-настоящему запоминающимся? Наверное, та самая атмосфера, которая заставляет забыть о времени. Когда вы заходите на RUVIDEO, чтобы посмотреть онлайн «Git Essentials: Must Know Commands #devops #git», вы рассчитываете на нечто большее, чем просто загрузку плеера. И мы это понимаем. Контент такого уровня заслуживает того, чтобы его смотрели в HD 1080, без дрожания картинки и бесконечного буферизации.
Честно говоря, Rutube сегодня — это кладезь уникальных находок, которые часто теряются в общем шуме. Мы же вытаскиваем на поверхность самое интересное. Будь то динамичный экшн, глубокий разбор темы от любимого автора или просто уютное видео для настроения — всё это доступно здесь бесплатно и без лишних формальностей. Никаких «заполните анкету, чтобы продолжить». Только вы, ваш экран и качественный поток.
Если вас зацепило это видео, не забудьте взглянуть на похожие материалы в блоке справа. Мы откалибровали наши алгоритмы так, чтобы они подбирали контент не просто «по тегам», а по настроению и смыслу. Ведь в конечном итоге, онлайн-кинотеатр — это не склад файлов, а место, где каждый вечер можно найти свою историю. Приятного вам отдыха на RUVIDEO!
Видео взято из открытых источников Rutube. Если вы правообладатель, обратитесь к первоисточнику.