Clone wiki

lifev-release / A-Style


Apply astyle

Artistic Style Version 2.02.1 With the following options:

    astyle \
        --style=allman \
        --indent=spaces=4  \
        --indent-switches \
        --indent-col1-comments \
        --pad-oper \
        --pad-paren-out \
        --pad-header \
        --convert-tabs \
        --break-closing-brackets \
        --add-brackets \
        --align-pointer=type \
        --max-instatement-indent=80 \
        --preserve-date \
        --lineend=linux \
        --suffix=none \
        --verbose \
        --recursive "*.*pp"

Rough Guidelines:

  • Never use rebase. use only merge --no-ff

  • frequently merge from master. E.g. every time it is modified.

  • if possible branch from master, and not from other branches. I.e., do it only if there is a good reason

  • remember who is your parent, and merge from parent instead of from master.

  • never copy files from one branch to the other. If needed and possible, cherry pick

  • never force a push to any branch, in particular master.

  • if your parent is not master and you really need to merge master, do the following (in order of importance):

  • ask your parent to merge from master, then merge from your parent

  • merge from master and swap role with your parent (i.e., now your branch is the parent, its children are now yours, and your parent is master)
  • merge master and abandon your parent. Your parent is therefore master

Short merge how-to

when you do a merge (git merge --no-ff "branch") which includes conflicts, you have to:

  • edit the unmerged files
  • add them
  • and git commit (use the default message!)\ Without the commit, your merge is not complete, and anything you do until the next commit, will appear as the commit resolution!

Configure your editor in the right way

Please read one of the following files to configure your editor !

  • lifev/tools/eclipse/README
  • lifev/tools/inspect/README
  • lifev/tools/emacs/README
  • lifev/tools/kdevelop/README