当前位置:网站首页>gerrit中如何切换远程服务器
gerrit中如何切换远程服务器
2022-07-31 15:45:00 【码龙-】
当你使用的远程服务器要更换的时候,即代码转移到新的gerrit服务器上了,是否一定需要重新配密钥,且需要重新拉代码呢。其实大可不必,重新拉一份代码太大费周章了,使用命令切换远程服务器即可。
以下是一个从192.168.8.67切换到192.168.1.80远程服务器的例子。
首先第一步,查看你当前的远程服务器地址:
使用git remote -v查看当前URL:
使用git remote -v命令后 可以看出当前的远程服务器为192.168.8.67,即当你使用git push 命令的时候,本地改动会提交到的远程服务器地址。
第二步:
使用git remote set-url origin <URL>重新设置URL。
使用git remout set-url origin <URL>改了响应的地址之后,再使用git remoute -v 查看当前的远程服务器地址,可以发现已经切换到192.168.1.80了。
第三步:
在第二步中已经成功的切换了远程服务器,此时使用git pull 命令即可正常的拉取代码了。
边栏推荐
- 第05章 存储引擎【1.MySQL架构篇】【MySQL高级】
- Insert into data table to insert data
- Efficient use of RecyclerView Section 2
- 工程水文学复习资料
- R language test whether the sample conforms to normality (test whether the sample comes from a normally distributed population): shapiro.test function tests whether the sample conforms to the normal d
- WPF project - basic usage of controls entry, you must know XAML
- 为什么黑客领域几乎一片男生?
- After Grafana is installed, the web opens and reports an error
- MySQL的相关问题
- 基于ABP实现DDD
猜你喜欢
Why is the field of hacking almost filled with boys?
Use of radiobutton
Why don't you make a confession during the graduation season?
[Meetup Preview] OpenMLDB+OneFlow: Link feature engineering to model training to accelerate machine learning model development
mongo enters error
radiobutton的使用
基于ABP实现DDD
The use of button controls
Kubernetes common commands
C language "the third is" upgrade (mode selection + AI chess)
随机推荐
浏览器自带的拾色器
R language moves time series data forward or backward (custom lag or lead period): use the lag function in the dplyr package to move the time series data forward by one day (set the parameter n to a p
为什么黑客领域几乎一片男生?
Foreign media right, apple on May be true in inventory
多主复制下处理写冲突(4)-多主复制拓扑
基于Redis(SETNX)实现分布式锁,案例:解决高并发下的订单超卖,秒杀
WPF项目--控件入门基础用法,必知必会XAML
Matlab矩阵基本操作(定义,运算)
Unity 之 图集属性详解和代码示例 -- 拓展一键自动打包图集工具
The normal form of the database (first normal form, second normal form, third normal form, BCNF normal form) "recommended collection"
【Meetup预告】OpenMLDB+OneFlow:链接特征工程到模型训练,加速机器学习模型开发
使用 GraphiQL 可视化 GraphQL 架构
工程水文学名词解释总结
[Meetup Preview] OpenMLDB+OneFlow: Link feature engineering to model training to accelerate machine learning model development
WPF project - basic usage of controls entry, you must know XAML
After Grafana is installed, the web opens and reports an error
update data table update
Insert into data table to insert data
TRACE32 - C source code association
Deployment应用生命周期与Pod健康检查