Creating a git repository on Manu Lab's Machines

From Manu and Loh Lab Wiki
Jump to navigation Jump to search

Location of repositories

All the git repositories are located in /labcommon/manulabrepos/ .

Each repository will be contained in its own directory. We will use a repository, "test.git" as an example.

Initializing a bare repository on blastula

  • Log in to blastula either using ssh or nomachine
  • Create a git respository
    • Create the directory that will contain the repository
cd /labcommon/manulabrepos/
mkdir test.git
chmod 2775 test.git
    • Initialize a "bare" repository. One may not check out branches in a
bare repository. The directory contains all the tracking/metadata files. In
a normal repository all these files are located in the .git directory.
However, it is not possible to push to a normal respository.
cd test.git
git init --bare --shared=group
This repository does not have any tracked files yet. In order to add files
to track, we will first clone this into a normal repository in your home directory on our machines or your ::laptop. Follow the instructions for Cloning a git repository from blastula.