If you did not migrate your account yet, visit https://idp-portal-info.suse.com/
- 1 OSC Collaboration edit
- 2 A typical workflow example
- 3 User documentation
- 4 Other useful commands
- 5 Contributing
OSC Collaboration edit
With the introduction of the collaboration features of the build service, everybody can now help with packaging in openSUSE. For GNOME, for instance, the development is done in the GNOME:Factory (G:F) project, and packages submitted there will then be submitted to openSUSE:Factory (oS:F) which is where the Factory distribution lives.
However, the command line for all this might be a bit hard for first-time users, and some of the usual workflow can actually be automated. That's why we created the osc collab plugin. This plugin provides three extremely useful commands: osc collab todo, osc collab update and osc collab setup. A few other commands are available.
A typical workflow example
First, let's look at what can be done (the output of the todo command is truncated in this example) for the GNOME:Factory project:
vuntz@lyon ~/work/opensuse/tmp/>osc collab todo --project GNOME:Factory Downloading data in a cache. It might take a few seconds... Package | openSUSE:Factory | GNOME:Factory | Upstream --------------------------------+------------------+------------------+----------------- anjuta | 2.23.91 | 2.23.91 | 220.127.116.11 (r) at-spi | 1.23.92 | 1.23.92 | 1.24.0 gdm | 2.23.92 | 2.23.92 (s) | 2.24.0 (s) gedit | 2.23.93 | 2.23.93 | 2.24.0
We can see that anjuta, at-spi, gdm and gedit all need an update in GNOME:Factory since there is a more recent version upstream. We notice that anjuta has already been reserved by somebody, so we can ignore it. Similarly, we notice that there is a submission for gdm waiting to be approved by a GNOME:Factory maintainer. So let's just ignore this one too. It's possible to automatically remove those lines with some arguments: osc collab todo --exclude-reserved --exclude-submitted (or osc collab t --xr --xs for people who prefer to not type long commands).
So let's work on updating gedit:
vuntz@lyon ~/work/opensuse/tmp/> osc collab update --project GNOME:Factory gedit Package gedit has been reserved for 36 hours. Do not forget to unreserve the package when done with it: osc collab unreserve gedit A /home/vuntz/work/opensuse/tmp/gedit A /home/vuntz/work/opensuse/tmp/gedit/gedit-2.23.93.tar.bz2 A /home/vuntz/work/opensuse/tmp/gedit/gedit-desktop.patch A /home/vuntz/work/opensuse/tmp/gedit/gedit.changes A /home/vuntz/work/opensuse/tmp/gedit/gedit.spec A /home/vuntz/work/opensuse/tmp/gedit/ready Package gedit has been checked out. gedit.spec has been prepared. gedit.changes has been prepared. Looking for the upstream tarball... gedit-2.24.0.tar.bz2 has been downloaded. Finding NEWS and ChangeLog information... NEWS between gedit-2.23.93.tar.bz2 and gedit-2.24.0.tar.bz2 is available in osc-gnome.NEWS ChangeLog between gedit-2.23.93.tar.bz2 and gedit-2.24.0.tar.bz2 is available in osc-gnome.ChangeLog Running quilt... Patches still apply. gedit-2.23.93.tar.bz2 has been removed from the package. gedit-2.24.0.tar.bz2 has been added to the package. Package gedit has been prepared for the update.
The output of this command is a bit verbose, but this way, you can be sure of what's going on. In this specific case, everything went fine and so it seems you only need to update gedit.changes.
So, you first change the current directory to the checked out package with cd gedit. And then, you can now open gedit.changes in your favorite editor. You'll notice that it's already prefilled:
------------------------------------------------------------------- Tue Sep 30 16:37:35 CEST 2008 - firstname.lastname@example.org - Update to version 2.24.0: + -------------------------------------------------------------------
So you only have to mention what has changed. The osc-collab.NEWS and osc-collab.ChangeLog files should be of some help here.
Now that you've updated gedit.changes, you should make sure that all patches in the package are still relevant and that the build and runtime dependencies are up-to-date. There is no magic way to do this, so it's all manual work.
The next steps are typically to commit your changes, make sure the package builds correctly and if this is the case submit it. You can do all this in one command: osc collab buildsubmit -m 'Update to 2.24.0'.
After the successful osc collab buildsubmit, the package will automatically be unreserved by default, unless you used the --no-unreserve option. You can alternatively manually unreserve the package: osc collab unreserve --project GNOME:Factory gedit
Alternative to buildsubmit
If you don't want to use osc collab buildsubmit, you can use the following instructions which are the typical commands used for collaboration in the build service. However, osc collab buildsubmit is enough in most of the cases.
- First, you can commit your changes to the build service: osc commit -m 'Update to 2.24.0'
- Once this is done, make sure that the package builds correctly -- either by checking the result of the build in the build service (on the web page or via osc results home:vuntz:branches:GNOME:Factory gedit) or by using osc build.
- If the build is successful, submit your package to GNOME:Factory with the following command: osc submitreq create -m 'Update to 2.24.0'
What can go wrong
- if you try to update a package which is already reserved by somebody, you will get an error. You can use the --ignore-reserved option to ignore this. You should only do this after communicating with the person who reserved the package.
- sometimes, some patches don't apply anymore. In this case, you will see that the 'quilt' step failed. You will have to fix this first.
|Variable||Default value||Command line option||~/.oscrc key to change it||Example|
|Projects||GNOME:Factory;||--project||collab_projects||collab_projects = GNOME:Factory;X11:common:Factory;GNOME:Contrib;|
|Repository||openSUSE_Factory||--repo||collab_repo||collab_repo = openSUSE_11.1|
|Architectures||i586;x86_64;||--arch||collab_archs||collab_archs = i586;|
|Package tracking||0||collab_do_package_tracking||collab_do_package_tracking = 1|
Other useful commands