Skip to content

Instantly share code, notes, and snippets.

@monaxmp
Last active June 18, 2018 15:52
Show Gist options
  • Select an option

  • Save monaxmp/2e8403be5ca0633ea37c04bc1d8d5326 to your computer and use it in GitHub Desktop.

Select an option

Save monaxmp/2e8403be5ca0633ea37c04bc1d8d5326 to your computer and use it in GitHub Desktop.
git command
------------------------------------------------------------------------------------------------------------
https://webhamster.ru/mytetrashare/index/mtb0/1413010541hzh3175lej
git checkout HEAD@{1}
-------------------------------
git branch temp
git checkout temp
git branch -f master temp
git checkout master
git branch -d temp
-------------------------------
Еще один вариант, короткий
git checkout имяВеткиГдеВыНаходитесь
---------------------------------------------------------------------------------------------------------------
git pull origin master
---------------------------------------------------------------------------------------------------------------
переименовать последний коммит и ребазе
git fetch --all
git reset --hard origin/master
git commit --amend -m "YandexDisk pause" //
git push --force
--------
Как сделать откат нескольких коммитов git
git reset --hard 96109b4
-----------
решение конфликтов merge
git mergetool
-----------
исключения файлов в Git
git rm -r --cached common/config/main-local.php
-----------
git fetch --all
git reset --hard origin/master
php yii migrate
composer update
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment