[pacman-dev] [PATCH] Clean way to separate local from sync dbs.

Travis Willard travis at archlinux.org
Sun Aug 26 22:42:17 EDT 2007


Introduce two new methods into the API - alpm_db_register_sync and
alpm_db_register_local, which replace the functionality of
alpm_db_register. which has now been flagged as deprecated.
db_register_local always returns the local DB, and db_register_sync will
always try to register a sync DB. This conceptually separates the local
DB from sync DBs in the code. Also updated the pacman frontend to use
the new functions. In addition, this changes the location of all sync
DBs in the filesystem from $DBPATH/$REPO to $DBPATH/sync/$REPO, This
removes the silly limitation that a sync DB couldn't be named 'local',
along with structurally separating sync DBs and the local DB in the
filesystem.

Signed-off-by: Travis Willard <travis at archlinux.org>
---
 lib/libalpm/alpm.h  |    8 +++++-
 lib/libalpm/db.c    |   67
++++++++++++++++++++++++++++++++++++++++++-------- lib/libalpm/db.h
|    9 ++++++- src/pacman/pacman.c |   10 +------
 4 files changed, 73 insertions(+), 21 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ae76154c0bb921f4e4f295aae59df59fab9ab4c6.diff
Type: text/x-patch
Size: 7124 bytes
Desc: not available
URL: <http://archlinux.org/pipermail/pacman-dev/attachments/20070826/66c13222/attachment.bin>


More information about the pacman-dev mailing list