guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#62264] [PATCH] Add 'guix locate' command


From: Ludovic Courtès
Subject: [bug#62264] [PATCH] Add 'guix locate' command
Date: Fri, 16 Jun 2023 16:25:45 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux)

Hi,

I fixed the typos/issues you reported.

"pelzflorian (Florian Pelz)" <pelzflorian@pelzflorian.de> skribis:

> I went on to test some things.  They are not very important, but still
> there are bugs:
>
> After deleting ~/.cache/guix/locate and cd’ing out of my home directory,
> then inside “guix shell -CW coreutils”, “guix locate ls” does not find
> ls.

Works for me:

--8<---------------cut here---------------start------------->8---
$ guix shell -CW -D guix
The following derivation will be built:
  /gnu/store/570gc0xgf6sijhjdgh406ykx7ysfckfp-profile.drv

building CA certificate bundle...
listing Emacs sub-directories...
building fonts directory...
generating GLib schema cache...
building directory of Info manuals...
building XDG desktop file cache...
building XDG MIME database...
building profile with 57 packages...
[env]$ ./pre-inst-env guix locate ls
coreutils-minimal@8.32 
/gnu/store/vqdsrvs9jbn0ix2a58s99jwkh74124y5-coreutils-minimal-8.32/bin/ls
coreutils@8.32       
/gnu/store/9a0cjh929maqvkxn3inv6jqbxn72fkx0-coreutils-8.32/bin/ls
coreutils@9.1        
/gnu/store/skcwbg8v0w643w71j9zx25cq0a6dwirs-coreutils-9.1/bin/ls
--8<---------------cut here---------------end--------------->8---

Note that ‘-W’ has the effect of sharing ~/.cache with the container.
That means that the database is already there.

> When I use “guix locate icecat”, it legitimately also locates a file
> lib/icecat/icecat in addition to the desired bin/icecat.  I try to
> filter by “guix locate bin/icecat” or “guix locate -g bin/icecat”, but
> it seems locate does not support file names with slashes.

Right: ‘guix locate’ only checks the “basename”; it does not let you
search on the absolute file name.  We could add an option to do that
later (say ‘-f’) but I thought it’s less frequently useful.

Thanks for testing and reporting back!

I’m sending the final version taking into account your comments and
those by Jelle.  I’ll push it in the coming days if there are no
objections.

Thanks!

Ludo’.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]