bzr qdiff fitxer.py
A continuació detallem les comandes que s'han realitzat per publicar el codi del mòdul moodleerpconnect (connector moodle ii OpenERP) des de zero.
resteve@talaia:~$ bzr init lp:~openerp-community/moodleerpconnect/trunk resteve@talaia:~$ bzr co lp:~openerp-community/moodleerpconnect/trunk resteve@talaia:~$ ls . .. trunk resteve@talaia:~$ mv trunk lp-moodle resteve@talaia:~$ mv moodle lp-moodle resteve@talaia:~$ cd lp-moodle resteve@talaia:~/lp-moodle$ bzr status unknown: moodle/ resteve@talaia:~/lp-moodle$ bzr add moodle adding moodle adding moodle/__init__.py adding moodle/__terp__.py adding moodle/moodle.py adding moodle/moodle_view.xml adding moodle/moodle_wizard.xml adding moodle/wizard adding moodle/wizard/__init__.py adding moodle/wizard/wizard_moodle_import_category.py adding moodle/wizard/wizard_moodle_import_course.py adding moodle/wizard/wizard_moodle_import_inscription.py adding moodle/wizard/wizard_moodle_import_student.py ignored 1 file(s). If you wish to add some of these files, please add them by name. resteve@talaia:~/lp-moodle$ bzr status added: moodle/ moodle/__init__.py moodle/__terp__.py moodle/moodle.py moodle/moodle_view.xml moodle/moodle_wizard.xml moodle/wizard/ moodle/wizard/__init__.py moodle/wizard/wizard_moodle_import_category.py moodle/wizard/wizard_moodle_import_course.py moodle/wizard/wizard_moodle_import_inscription.py moodle/wizard/wizard_moodle_import_student.py resteve@talaia:~/lp-moodle$ bzr ci -m "[ADD] Moodle connector first version" Committing to: bzr+ssh://bazaar.launchpad.net/~openerp-community/moodleerpconnect/trunk/ added moodle added moodle/__init__.py added moodle/__terp__.py added moodle/moodle.py added moodle/moodle_view.xml added moodle/moodle_wizard.xml added moodle/wizard added moodle/wizard/__init__.py added moodle/wizard/wizard_moodle_import_category.py added moodle/wizard/wizard_moodle_import_course.py added moodle/wizard/wizard_moodle_import_inscription.py added moodle/wizard/wizard_moodle_import_student.py Committed revision 1.
bzr ci -m "missatge" --fixes=lp:12345
on 12345 és el número de bug
Crearem una branca via web. Una vegada creada, només ens deixarà l'opció “push”. No estarà habilitat el “branch”. Aquesta branca està “This branch has not been pushed to yet.”.
Per completar la branca, un truc es:
bzr init bzr push lp:~zikzak/+junk/joomla --use-existing-dir
Si refresquem ràpidament, un missatge ens dirà que Launchpad està generant la branca. Finalment ens dirà: This branch is empty.
A partir d'ara, ja podem pujar codi amb:
bzr commit -m "missatge"
Recordar una vegada pujat el codi, actualitzar la branca amb:
bzr push lp:~zikzak/+junk/joomla
1. Ens baixem la branca original:
$ bzr branch lp:oosalespromotions
2. Creem una branca a partir de l'orginal (el últim commit de la branca orginal es trobarà en el nostre històric)
$ bzr push lp:~zikzak/oosalespromotions/sale_promotions
3. Ens baixem la nova branca que hem creat de nou:
bzr branch lp:~zikzak/oosalespromotions/sale_promotions
4. Fem un reconfigure perque faci ús de la branca de launchpad
bzr reconfigure --checkout
3. Ja podem fer un commit a la nostra branca. Després, podem fer un merge.
bzr commit -m "[IMP] Translation and security rules"
Una vegada descarregada la branca, haurem de reconfigurar que els commits es guardin a Launchpad (i no en local/root)
bzr reconfigure --checkout
bzr merge 391..396 lp:magentoerpconnect