I promised to do this a while ago. This is how you work with the new SVN layout:

UPDATE PACKAGES
---------------
Check out the package:
$ archco pkgname
$ cd pkgname/trunk/
If the package is already checked out:
$ cd pkgname
$ svn up
$ cd trunk/
This is important so there won't be any conflicts later! If you forget to svn up, you can still solve the problems that may occur, but this is way easier.

Now do whatever you have to do and run makepkg, namcap etc. Now run {core,extra,testing}pkg. This uploads the package, checks the integrity and runs 'archrelease repo-arch'. archrelease seems to be buggy sometimes, so make sure it actually adds files to repos/repo-arch - you can see that from the output (something like "Sending repos/repo-arch/PKGBUILD" I thknk). The db scripts look inside pkgname/repos/repo-arch to find the right PKGBUILD!

Now you're done. Log on to gerolde and run the db scripts as usual.

MODIFY A PACKAGE WITHOUT CHANGING trunk/
----------------------------------------
When a package is in testing, the files in trunk pretty much reflect the stuff in testing. What if you want to update the package in core/extra without changing trunk/testing?

Just
$ cd repos/extra-i686
edit the files, build and so on. However, devtools won't help you now. You have to upload the file yourself using scp and
$ svn commit -m "some commit message"
Then you can run the db script.

ADD A NEW PACKAGE
-----------------
You don't want to check out the whole tree, it's huge. Therefore, you just
$ svn co -N svn+ssh://archlinux.org/home/svn-packages somedir
$ cd somedir
$ mkdir -p pkgname/{trunk,repos}
$ svn add pkgname/{,trunk,repos}
$ cd pkgname/
$ svn commit -m "Add package pkgname"
$ cd trunk/
Now add all the files like the PKGBUILD, don't forget to run
$ svn add PKGUILD pkgname.install somefile1 somefile2
Now proceed like above.

ALTERNATIVE WAY OF CHECKING OUT
DELETING A PACKAGE
-------------------------------
I didn't test this, but Aaron tells me it'll work. Instead of using archco, you can do a non-recursive checkout like above:
$ svn co -N svn+ssh://archlinux.org/home/svn-packages somedir
$ cd somedir
Now you can checkout single packages, too:
$ svn up pkgname
Or delete a package
$ svn up pkgname
$ svn rm pkgname
Or add one like I showed above.
This will make the archco script obsolete, maybe you like this method better.

MAKING IT FASTER
----------------
extrapkg establishes many ssh connections during your work. This always takes a few seconds and thus slows you down. You may even have to type your password many times. This will help:

Add the following lines to ~/.ssh/config:
ControlPath /home/youruser/.ssh/master-%h-%p-%r

Host gerolde
HostName archlinux.org

Host cvs.archlinux.org
HostName archlinux.org

Host svn.archlinux.org
HostName archlinux.org

The last few lines are aliases, so the hosts gerolde, archlinux.org, cvs.archlinux.org and svn.archlinux.org are treated as if they all were "archlinux.org". Now establish one connection with
$ ssh -M archlinux.org
The -M option creates a socket in the ControlPath and other ssh clients connecting to the same host and port will use this socket instead, and be tunneled through the master connection. Thus, you never have to enter your password again until you close the connection. Even better, establishing a connection (like scp, svn etc do) is much faster.

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to