Github: Difference between revisions

From DISI
Jump to navigation Jump to search
No edit summary
 
(15 intermediate revisions by 2 users not shown)
Line 1: Line 1:
This page describes how to use github, which is our version control system.  
This page describes how to use github, our [[version control]] system. This page is only relevant to [[:Category:Developer | software developers]].


= Getting Started =
= Create an account on github.com =
* Request an account on github. You can request a free one.
It's free. Write to the [[sysadmin]]s asking to have access to our repositories, as in https://github.com/docking-org.
* write to the sysadmins asking to have access to our repositories (see below for a list).
= Set up for ssh access =
Go to https://github.com/settings/ssh and paste your public key in the box


= Getting a fresh copy of a repository and starting to use it =
see the following wiki page on how to generate a ssh key pair:
[[How_to_generate_ssh_keys_securely]]


Note that if you use a custume name you will need to make a configure file:


= Comitting your first change =
>>cat ~/.ssh/config


Host github github.com
    HostName github.com
    IdentityFile ~/.ssh/custume_name
    User username




= Best practices for the lab =
{{TOCright}}
== When and how to branch / merge ==


== When and how to create a new repository ==
= Fork for Development =
Go to https://github.com/docking-org/DOCK
Click "Fork" to create your own working copy
On your development machine and set the the trunk as upstream:


git clone git@github.com:[YOUR_USERNAME_HERE]/DOCK.git
cd DOCK
git remote add origin git@github.com:[YOUR_USERNAME_HERE]/DOCK.git
git remote rm upstream
git remote add upstream git@github.com:docking-org/DOCK.git
After making some changes, save them locally on your machine:
git commit -m "I changed test/file-abc" test/file-abc
or
git commit -a -m "I changed all the files"
After a series of changes are ready to push remotely
git push
If these changes should be added to the master DOCK branch


== Merging legacy code into github ==
Go to https://github.com:[YOUR_USERNAME_HERE]/DOCK.git
 
Click "Pull Request" in the upper-right corner of the file listing
== Backups ==
Click "Click to create a pull request for this comparison"
Add any additional notes you may want
Press "Send pull request"
If you are an administrator in the primary DOCK repository, click "Merge pull request" , add any comments wanted, then click "Confirm merge" and the changes will be added to the DOCK trunk
To update your fork with the trunk
git pull upstream master
git push


= Guidance =
* best practices for when and how to branch/merge
* when and how to create a new repository


= Lab repositories =
= Lab repositories =
* docking-org/ZINC
* docking-org/DOCK - [[DOCK 3]] series software, currently [[DOCK 3.7]]
 
* docking-org/ZINC - ZINC database creation, curation, management and interface
* docking-org/cluster - tools for managing a cluster
* docking-org/internal- our private scripts not part of another distribution


= Friends of the lab's repositories =
* rdkit/rdkit - The official sources for the RDKit library
* ryancoleman/analysis-scripts - Some simple scripts for analyzing lists of data, both paired & unpaired.
* madgpap/chembl_clippy - cross platform molecular structure rendering app
* metamolecular/osra - Optical structure recognition software, OSRA source from http://cactus.nci.nih.gov/osra/


[[Category:Internal]]
[[Category:Developer]]
[[Category:Sysadmin]]

Latest revision as of 18:50, 27 August 2014

This page describes how to use github, our version control system. This page is only relevant to software developers.

Create an account on github.com

It's free. Write to the sysadmins asking to have access to our repositories, as in https://github.com/docking-org.

Set up for ssh access

Go to https://github.com/settings/ssh and paste your public key in the box

see the following wiki page on how to generate a ssh key pair: How_to_generate_ssh_keys_securely

Note that if you use a custume name you will need to make a configure file:

>>cat ~/.ssh/config

Host github github.com
    HostName github.com
    IdentityFile ~/.ssh/custume_name
    User username


Fork for Development

Go to https://github.com/docking-org/DOCK Click "Fork" to create your own working copy On your development machine and set the the trunk as upstream:

git clone git@github.com:[YOUR_USERNAME_HERE]/DOCK.git
cd DOCK
git remote add origin git@github.com:[YOUR_USERNAME_HERE]/DOCK.git
git remote rm upstream
git remote add upstream git@github.com:docking-org/DOCK.git

After making some changes, save them locally on your machine:

git commit -m "I changed test/file-abc" test/file-abc

or

git commit -a -m "I changed all the files"

After a series of changes are ready to push remotely

git push

If these changes should be added to the master DOCK branch

Go to https://github.com:[YOUR_USERNAME_HERE]/DOCK.git Click "Pull Request" in the upper-right corner of the file listing Click "Click to create a pull request for this comparison" Add any additional notes you may want Press "Send pull request" If you are an administrator in the primary DOCK repository, click "Merge pull request" , add any comments wanted, then click "Confirm merge" and the changes will be added to the DOCK trunk To update your fork with the trunk

git pull upstream master
git push

Guidance

  • best practices for when and how to branch/merge
  • when and how to create a new repository

Lab repositories

  • docking-org/DOCK - DOCK 3 series software, currently DOCK 3.7
  • docking-org/ZINC - ZINC database creation, curation, management and interface
  • docking-org/cluster - tools for managing a cluster
  • docking-org/internal- our private scripts not part of another distribution

Friends of the lab's repositories

  • rdkit/rdkit - The official sources for the RDKit library
  • ryancoleman/analysis-scripts - Some simple scripts for analyzing lists of data, both paired & unpaired.
  • madgpap/chembl_clippy - cross platform molecular structure rendering app
  • metamolecular/osra - Optical structure recognition software, OSRA source from http://cactus.nci.nih.gov/osra/