Sto cercando di implementare un modello di ramificazione simile a git-flow, ma più semplice (nessun release o hotfix rami).
L'idea è di avere il ramo master sempre aggiornato con l'ultima versione taggata, un ramo develop che viene eseguito parallelamente ad esso e% ramifeature da implementare più a lungo (più di 1-2 commit) caratteristiche.
develop rami da master e di nuovo in esso, mentre i rami feature fanno lo stesso nel ramo develop .
Questo è il mio modello di ramificazione:
# 1. While in master, create develop branch, and track it.
# This branch is created once here.
git checkout -b develop
git push --set-upstream origin develop
# 2. Do some minor work and push to develop
git add <file>
git commit -m 'did work'
git push
# 3. To work on a feature, create a branch from develop, and track it
git checkout -b feat/issue9
git push --set-upstream origin feat/issue9
# 4. After work on feature is finished, merge into develop
git checkout develop
git merge --no-ff feat/issue9
# Delete remote and local branches
git push origin --delete feat/issue9
git branch -d feat/issue9
git push
# 5. Once a new release is ready, bump version
git add __version__
git commit -m 'Bumped version number to 0.1'
# 6. Add tag
git tag -a v0.1
git push --tags
# 7. Merge develop into master, and push changes
git checkout master
git merge --no-ff develop
git push
Fino a questo punto, i rami si presentano così:
Questoèquasiciòchevoglio,trannechedevelopèdietromasterdiduecommit(ilbumpingdelfile__version__el'unionedidevelopinmaster)
Quindicercodiportaredevelopfinoadovemasterè:
#8.Mergemasterintodevelopgitcodevelopgitmergemastergitpushcherisultainquesto:

Unavoltaraggiuntoquestopunto,ricomincioda2.Dosomeminorworkandpushtodevelop.Unsecondociclohaunaspettosimileaquesto:
Questo è un modello ragionevole da seguire? Può darmi problemi in futuro? Qualche consiglio per migliorarlo?
