其他分享
首页 > 其他分享> > Apollo自动驾驶虚拟仿真赛笔记[3]-完成第一个场景并生成patch文件(未完待续)

Apollo自动驾驶虚拟仿真赛笔记[3]-完成第一个场景并生成patch文件(未完待续)

作者:互联网

场景描述

planning模块

备注

在 场景 中,单击 请选择场景,进入批量运行的场景选择界面。在自动驾驶场景选择页面,您可以按需选择适合的场景。目前支持通过搜索关键字或筛选场景标签来找到理想的场景,也支持选择用户自定义场景分组。提交场景选择结果后,在新建任务页面可看到已选择的场景数量。
在 Git仓库地址 中,上传 Git 可公开访问的仓库地址。
在 分支/Commit Id 中,选择一个分支或输入一个 commit 以决定编译和测试的代码版本。注意:仅支持运行 Fork 自 Apollo2.0.0 及以后版本的代码。
在 Git分支名称 中,选择分支名称。

git设置,准备提交代码

准备工作目录

思路:gitlab创建公开项目->fork gitee的apollo->pull to gitlab->更改文件也pull

mkdir /apollo_contest
git init
git clone -b edu_sim_contest git@gitee.com:ApolloAuto/apollo.git
git remote add origin git@gitlab.com:paisheng1/temp_apollo_contest.git(你的git地址)
git add .
git push origin master -force



error: src refspec master does not match any

原因本地仓库为空
git add .
git commit -m "test4"

查看

git remote -v显示所有远程仓库
git remote show 别名
git status查看仓库状态
git log 查看提交日志
git branch 查看分支

error: failed to push some refs to 'git@gitlab.com:paisheng1/temp_apollo_contest.git'

hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
解决办法git push gitlab master --force

gitignore 忽略某些文件

在 Git 中,我们可以用 git add 要告诉 Git 文件冲突已经解决
运行git config core.ignorecase false,关闭git忽略大小写配置,即可检测到大小写名称更改

使用git format-patch制做patch文件

使用以下任意一条指令即可,第一条指令中的HEAD~1中的数字1即为上一步操作中数出来的commit数。使用该方法可以将多个commit制作为1个patch文件。

提交代码

(笔者还没完成)

标签:Git,git,remote,apollo,gitlab,patch,未完待续,场景,Apollo
来源: https://www.cnblogs.com/qsbye/p/16325507.html