Исходный код вики Сценарии
Редактировал(а) Alexandr Fokin 2024/02/02 13:13
Скрыть последних авторов
| author | version | line-number | content |
|---|---|---|---|
| |
1.9 | 1 | |(% style="width:464px" %)Переместить файл или папку (в рамках одной ветки) с сохранением истории изменений|(% style="width:1020px" %){{code language="cmd"}}git mv <SrcFileOrDirectoryName> <DestinationDirectoryName>{{/code}} |
| 2 | |(% style="width:464px" %)Обновить список удаленных веток | ||
| 3 | |(% style="width:1020px" %){{code language="cmd"}}git remote update <RepositoryAlias> --prune{{/code}}((( | ||
| |
1.6 | 4 | (RepositoryAlias по умолчанию: origin) |
| 5 | ))) | ||
| |
1.9 | 6 | |(% style="width:464px" %)Загрузка ветки|(% style="width:1020px" %)((( |
| |
1.6 | 7 | (% id="cke_bm_1192S" style="display:none" %) (%%)Загрузить и сделать активной ветку |
| |
1.1 | 8 | |
| |
1.6 | 9 | How to download a branch with git? |
| 10 | [[https:~~/~~/stackoverflow.com/questions/2294313/how-to-download-a-branch-with-git>>https://stackoverflow.com/questions/2294313/how-to-download-a-branch-with-git]] | ||
| |
1.1 | 11 | |
| |
1.6 | 12 | {{code language="cmd"}} |
| 13 | git branch --track <LocalBranchName> origin/<RemoteBranchName> | ||
| 14 | git checkout <LocalBranchName> | ||
| 15 | {{/code}} | ||
| 16 | ))) | ||
| |
1.9 | 17 | |(% style="width:464px" %)Отправить одну определенную ветку в определенный репозиторий|(% style="width:1020px" %)((( |
| |
1.6 | 18 | Отправить одну определенную ветку в определенный репозиторий (в том числе в пустой) |
| |
1.1 | 19 | |
| |
1.6 | 20 | {{code language="cmd"}} |
| 21 | git remote add <RepositoryAlias> <RepositoryUrl> | ||
| 22 | git checkout <LocalBranchName> | ||
| 23 | git push -u <RepositoryAlias> <LocalBranchName>:<RemoteBranchName> | ||
| 24 | git remote remove <RepositoryAlias> | ||
| 25 | {{/code}} | ||
| 26 | ))) | ||
| |
1.9 | 27 | |(% style="width:464px" %) |(% style="width:1020px" %) |
| 28 | |(% style="width:464px" %)Перенести commit из одной ветки в другую|(% style="width:1020px" %)((( | ||
| |
1.1 | 29 | Как в Git перенести commit из одной ветки в другую? |
| 30 | [[http:~~/~~/paratapok.ru/developer-tools/2593_kak-v-git-perenesti-commit-iz-odnoj-vetki-v-druguyu/>>http://paratapok.ru/developer-tools/2593_kak-v-git-perenesti-commit-iz-odnoj-vetki-v-druguyu/]] | ||
| 31 | |||
| |
1.6 | 32 | {{code language="cmd"}} |
| 33 | git cherry-pick | ||
| 34 | {{/code}} | ||
| 35 | ))) | ||
| |
1.9 | 36 | |(% style="width:464px" %)Вынесение отдельно взятой папки из конкретной ветки в другую ветку с полным сохранением ее истории.|(% style="width:1020px" %)((( |
| |
1.6 | 37 | |
| |
1.1 | 38 | |
| 39 | {{code language="cmd"}} | ||
| 40 | git subtree split -P <DirectoryName> -b <NewBranchName> | ||
| 41 | {{/code}} | ||
| 42 | |||
| 43 | Detach (move) subdirectory into separate Git repository | ||
| 44 | [[https:~~/~~/stackoverflow.com/questions/359424/detach-move-subdirectory-into-separate-git-repository/17864475#17864475>>https://stackoverflow.com/questions/359424/detach-move-subdirectory-into-separate-git-repository/17864475#17864475]] | ||
| |
1.6 | 45 | ))) |
| |
1.9 | 46 | |(% style="width:464px" %)Прервать слияние|(% style="width:1020px" %){{code language="cmd"}}git merge --abort{{/code}} |
| 47 | |(% style="width:464px" %)git submodule|(% style="width:1020px" %)((( | ||
| 48 | |((( | ||
| 49 | How to see which commit a git submodule points at | ||
| 50 | [[https:~~/~~/stackoverflow.com/questions/20655073/how-to-see-which-commit-a-git-submodule-points-at>>https://stackoverflow.com/questions/20655073/how-to-see-which-commit-a-git-submodule-points-at]] | ||
| |
1.1 | 51 | |
| |
1.9 | 52 | {{code language="cmd"}} |
| 53 | git submodule status | ||
| 54 | {{/code}} | ||
| 55 | )))| | ||
| 56 | | | | ||
| 57 | ))) | ||
| 58 | |(% style="width:464px" %) |(% style="width:1020px" %) | ||
| 59 | |||
| |
1.1 | 60 | ---- |
| 61 | |||
| |
1.6 | 62 | ==== Внутренние ссылки: ==== |
| |
1.1 | 63 | |
| |
1.6 | 64 | ====== Дочерние страницы: ====== |
| |
1.1 | 65 | |
| |
1.6 | 66 | {{children/}} |
| |
1.1 | 67 | |
| |
1.6 | 68 | ====== Обратные ссылки: ====== |
| 69 | |||
| 70 | {{velocity}} | ||
| 71 | #set ($links = $doc.getBacklinks()) | ||
| 72 | #if ($links.size() > 0) | ||
| 73 | #foreach ($docname in $links) | ||
| 74 | #set ($rdoc = $xwiki.getDocument($docname).getTranslatedDocument()) | ||
| 75 | * [[$escapetool.xml($rdoc.fullName)]] | ||
| 76 | #end | ||
| 77 | #else | ||
| 78 | No back links for this page! | ||
| 79 | #end | ||
| 80 | {{/velocity}} | ||
| 81 | |||
| |
1.1 | 82 | ---- |