Skip to content

为项目添加git template,并从远程仓库拉取更新

Published: at 09:09 PMSuggest Changes

Table of Contents

Open Table of Contents

添加远程模板仓库

git remote add template [template repo url]

拉取所有更新

git fetch --all

与远程仓库模板的指定分支合并

git merge template/[branch name]
# 如果有报错`fatal: refusing to merge unrelated histories`,请加上`--allow-unrelated-histories`

Managing remote repositories - GitHub Docs


Next Post
使用Fly.io部署OpenCat for Team