Thursday, September 21, 2017

GIT setup for multiple users in Linux environment

A long time, I was away from posting anything here...

There are situations when people working on some project where they need to setup temporary version control for development threads. It is before they take it to logical control and that's when the project shall go to the central repository be it the same repository tool or different. In this case, we started to work on a project where we wanted to reach to a level before we checkin in the mail repository. Hence, we setup the GIT repository quickly.

It was a setup created to work in the same filesystem on linux machine. The steps which were followed to create the setup is as follows -

The git version used need to be setup -

  $ set path = ( //git-2.11.0/bin/ $path )
  $ git --version

In order to initialize the git repository -

  $ git init

A directory to initiate -
  $ mkdir




  $ touch /test

Adding these files to repository -

  $ git add fpga_testchip/test
  $ git status
  $ git commit

You can add and annotate the users to get the notifications in future and associate users to the repository -
  $ git config --global user.email "username@synopsys.com"
  $ git config --global user.name "username"

Adding another directory -

  $ git add
  $ git commit
  $ git log

In order to set up the remote server so that the repository could be accessed.

  $ git remote add /base/a/b/.git
  $ git push


  $ git push --set-upstream master

Another user need to run following command to clone the repository for his own usage -

git clone /base/a/b/.git

Further, the user could start adding his stuff in the repository and add, checkin his changes. In order to reflect it in global repository, user need to push his changes.

Happy GITing !!