Book Image

Git: Version Control for Everyone

By : Ravishankar Somasundaram
Book Image

Git: Version Control for Everyone

By: Ravishankar Somasundaram

Overview of this book

<div> <div>Git – is free software which enables you to maintain different versions of single or multiple files present inside a directory(folder), and allows you to switch back and forth between them at any given point of time. It also allows multiple people to work on the same file collaboratively or in parallel, without being connected to a server or any other centralized system continuously.<br /><br />This book is a step by step, practical guide, helping you learn the routine of version controlling all your content, every day. <br /><br />If you are an average computer user who wants to be able to maintain multiple versions of files and folders, or to go back and forth in time with respect to the files content – look no further. The workflow explained in this book will benefit anyone, no matter what kind of text or documentation they work on.<br /><br />This book will also benefit developers, administrators, analysts, architects and anyone else who wishes to perform simultaneous, collaborative work, or work in parallel on the same set of files. Git's advanced features are there to make your life easier.<br /><br /><br /><br /><br /><br /></div> </div>
Table of Contents (16 chapters)
Git: Version Control for Everyone Beginner's Guide
Credits
About the Author
Acknowledgement
About the Reviewers
www.PacktPub.com
Preface
Index

Time for action – team members get sync with the central bare repo


  1. Bob feels it's been a while since he received updates from the bare repos so he pulls to get the latest changes, with the results being as follows:

  2. Well, finally let's not forget the source repository, mother of all these repositories, for the update. Before doing a git pull from there we should point to the origin as the bare repository, and then perform a pull operation. The commands are as follows:

    git remote add origin /path/to/bare_collab
    git pull –u origin master
    

    This gives us an output as shown in the following screenshot:

As we have learned in Time for action – adding a remote origin in Chapter 4, Split the Load – Distributed Working with GIT, adding a remote would be a one time operation.

We can manually open the file or do a git log to see the changes taking effect across repositories.

What just happened?

We have successfully synced the changes across different repositories made by different people on the same...