falconindy / expac

alpm data extraction utility
91 stars 15 forks source link

expac -Ss returns empty when DBPath is uncommented in pacman.conf #19

Closed alfplayer closed 9 years ago

alfplayer commented 9 years ago

Even if it's left to the default value which is /var/lib/pacman/

E.g.: expac -Ss %n

falconindy commented 9 years ago

Are you sure your problem isn't fixed by ea25d7e51c2236e739aef2718499781dd37ef53d?

alfplayer commented 9 years ago

Yes, I tested this with git HEAD and expac 4-2. And on multiple systems. I also tested it adding a search pattern as argument.

falconindy commented 9 years ago

As described in your original report, I can't replicate your bug at HEAD (but I can at the v4 tag). Could you provide your whole pacman.conf?

alfplayer commented 9 years ago

I've just replicated it again on a clean installed system. pacman.conf only differs in that character from the original. Here I compare package.git version with my version uploaded to http://ix.io/fnE

$ curl -s https://projects.archlinux.org/svntogit/packages.git/plain/trunk/pacman.conf.x86_64?h=packages/pacman > pacman.conf.packages
$ curl -s http://ix.io/fnE > pacman.conf.alfplayer
$ git diff --word-diff pacman.conf.{packages,alfplayer}
diff --git a/pacman.conf.packages b/pacman.conf.alfplayer
index f43fe39..53b30fb 100644
--- a/pacman.conf.packages
+++ b/pacman.conf.alfplayer
@@ -10,7 +10,7 @@
# The following paths are commented out with their default values listed.
# If you wish to use different paths, uncomment and update the paths.
#RootDir     = /
[-#DBPath-]{+DBPath+}      = /var/lib/pacman/
#CacheDir    = /var/cache/pacman/pkg/
#LogFile     = /var/log/pacman.log
#GPGDir      = /etc/pacman.d/gnupg/
alfplayer commented 9 years ago

To confirm the version:

[root@archlinux-latest-vanilla expac]# ./expac --help |& head -1
expac 4-1-gea25d7e
[root@archlinux-latest-vanilla expac]# ./expac -Ss %n .         
[root@archlinux-latest-vanilla expac]# 
falconindy commented 9 years ago

Thanks, your config shows me what the problem is. Should be fixed by d4ab6ef08723c2c47802fd56222bf6105919ec3b.

alfplayer commented 9 years ago

It works here now. Thanks.