Skip to content
This repository has been archived by the owner on Jun 28, 2024. It is now read-only.

Latest commit

 

History

History
69 lines (40 loc) · 1.57 KB

HowToGitNabLab.md

File metadata and controls

69 lines (40 loc) · 1.57 KB

How to make a contribute to NabLab project with Git

  1. Create a fork of NabLab project:

  1. Setup (optionnal):

  • Publish changes to your fork by default (named origin):

git config remote.pushdefault origin

  • Use the same name of current branch to publish changes to repo:

git config push.default current

  1. Set reference:

  • Add main NabLab repo (will be named upstream) as reference:

git remote add upstream https://github.com/cea-hpc/NabLab.git

  • Make your fork up to date:

git fetch upstream

git pull upstream master

  1. Create a branch to work (optionnal):

  • Our contribution branch will automatically track the upstream/master branch:

git checkout -b contribution upstream/master

  1. Do your stuff:

  • add, commit, ...
  1. Publish your contribution:

  • If you've follow the 2. Setup, just

git push

  • Now go to web interface and ask for a pull-request
  1. If you need to fix your code:

  • git add --update
  • git commit
  • git push
  1. Updated upstream just before your pull-request:

  • If the reference is updated before your pull request is accepted, you can rebase your branch:

git pull --rebase

git push --force-with-lease