Git : contribution workflow

“git contribution workflow” … i use it when i have finish something i want to propose for acceptation to synfig / master.
This workflow assume you have forked synfig in github and som other little things.

Contribution workflow

  • check the branch / (fr) verif de branche!


git checkout master
  • check file text syntax (space, cr…) / (fr) verif format fichiers (espace / cr …)


git diff --check

gitk --> git gui
select file in the no indexed file list you want to commit, if brun color in code part appear, let review code. - refresh with gitk! (ctrl-f5)
i selection dans la liste fichier non indexé des fichiers modifé devant etre commité, si ya du brun dans le source - rafraichissiment avec gitk ! (ctrl-f5)[/i]

  • verif commit modification in graphic mode / (fr) verification des modification du commit en mode graphique
    gitk —> diff-path

  • comment your commit (and also your code :wink: / (fr) commente ton commit (ton code aussi…)
    gitk ----> git gui
    git gui —> comment / (fr) commenter

  • commit your commit / (fr) commit ton commit
    git gui —> menu / commit / commiter - (ctrl-return)

  • check the result / (fr) verification du resultat
    gitk , menu / file / reload (ctrl-f5) :
    yellow dot, master in bold and commit name (ok), red dot (ko) something not commited?.
    point jaune dans gitk , master gras et nom du commit (ok), point rouge si pas bon (ko) truc pas commité?.

get out from the pc ! / (fr) sort la modif de ton ordi !

  • check the branch / (fr) verif de branche!
    git checkout master

  • refresh the code / (fr) rafraichissement du code !

git fetch upstream
  • do rebase / (fr) fait rebase
git rebase upstream/master

–Nop ! (red dot in gitk, modif cancel or not commited / (fr) point rouge dans gitk, modif non annulé ou commité)
“Cannot rebase: You have unstaged changes. Please commit or stash them.”

–Yep! (yellow dot in gitk, master in blod and commit name / (fr) point jaune dans gitk , master gras et nom du commit)
First, rewinding head to replay your work on top of it…
Applying: “your commit comment” / (fr) “votre commentaire de commit”

  • push in your gitbase / (fr) pousse sur le serveur git a toi
    git push origin master --force
    log and pwd required / (fr) login et mot de passe demandé

  • it is a time to build … / (fr) bon c’est quand l’ultime moment de voir si tout fonctionne encore … hein.
    build - release/debug and retest !

  • do your pull request / (fr) fait ton pull request
    on tha web , connect to git , in you mirror depot hit the pull request button, re-comment and done !
    (fr) sur le web, connexion sur git ; depuis ton mirroir “button pull request” recommente … et hop!

some extra links in bonus … -un-projet … hes_in_Git … d-sous-git

And another thank’s to Genete & Z’gadis for helping me setting that well !

In the little (very important) things …this one for example :

a git remote rename 'source' 'destination' with upstream as ‘destination’ .

And this very little important things about the upstream name configuration is not clearly signaled anywhere (i mean wiki/search and forum/search )
Should that be added to ?


The remote name is something personal and each one can use its own definition. Anyone who knows how to use git should know that ‘upstream’ or ‘origin’ is the local name of your remote repository where you push things.
In my case I have it called ‘ghorigin’ and it stands for: git hub origin. My personal remote is called simply ‘genete’ :wink: