使用Git(Bitbucket)更新本地仓库 [英] Update a local repo with Git (Bitbucket)

查看:260
本文介绍了使用Git(Bitbucket)更新本地仓库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近切换到Bitbucket/git系统来处理我的代码,但在理解上有些麻烦.

I switched recently to a Bitbucket/git system to work on my code, and i'm having some troubles understanding.

这是我所做的:

  • 在Bitbucket上创建一个存储库,将我的所有代码从计算机A推送到其中.
  • 在计算机B上,我克隆了此代码并对其进行了处理.我在Bitbucket上推送了所有修改.

但是现在,这可能非常简单,但是我不知道如何取回我在计算机A上推送(最新提交)的修改...

But now, it may be very simple, but I don't know how I get back my modifications I push (the latest commits) on my computer A...

我尝试按照文档中的说明进行分叉,但它正在创建另一个存储库...我不明白:(

I tried forking as written on the doc, but it's creating another repo... I don't get it :(

谢谢您的回复!

推荐答案

您需要在计算机A的本地存储库中进行更改.运行以下命令(假设您的分支名称为master)

You need to pull your changes in your local repo on computer A. Run the following (assuming your branch name is master)

git pull origin master

有关git的基本指南,请查看 http://rogerdudler.github.io/git-指南/

For a basic guide to git, check out http://rogerdudler.github.io/git-guide/

这篇关于使用Git(Bitbucket)更新本地仓库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆