[packagekit] PackageKitExtra - package abstraction
Richard Hughes
hughsient at gmail.com
Tue Feb 19 02:37:09 PST 2008
On Tue, 2008-02-19 at 10:37 +0100, Patryk Zawadzki wrote:
> On Feb 18, 2008 6:59 PM, Richard Hughes <hughsient at gmail.com> wrote:
> > On Mon, 2008-02-18 at 12:09 +0100, Sebastian Heinlein wrote:
> > > To achive this all .desktop files are extracted from the archive and
> > > stored in a cache with some extra information. Currently all desktop
> > > files are shiped in the app-install-data package so that the cache can
> > > be rebuild afterwards again.
>
> That's a horrible horrible hack and would be a huge pain to maintain
> in a consistent and up-to-date way for any distro with daily updates
> (think "* unstable" or always-in-development distros).
Well yes, but we need to get the metadata from somewhere - and none of
the repo structures give us this sort of localised and icon information.
Worst case scenario, we just display the box icon and en_US text.
> > > renate at laptop:~$ ncftp ftp.ubuntu.com
> > > The program 'ncftp' can be found in the following packages:
> > > * ncftp
> > > * ncftp2
> > > Try: sudo apt-get install <selected package>
> > > bash: ncftp: command not found
> > This is very cool for new users and something that I've sorely wanted in
> > Fedora for new users. How do you generate the binary->package table and
> > keep it updated?
>
> Just ask repo indices for a package that contains a particular binary?
> Looks like backend's job.
Sure, but:
[hughsie at hughsie-laptop libpackagekit]$ pkcon search file /usr/bin/ftp
installed ftp i386 0.17-43.fc8 installed The standard UNIX FTP (File Transfer Protocol) client................]
available ftp i386 0.17-43.fc8 updates The standard UNIX FTP (File Transfer Protocol) client
search-file runtime was 4.6 seconds
We would need to cache this to make it sub 200ms.
> > On top of this it is trivial to build an executable like
> > pk-command-not-found which does the prompting for installation (rather
> > than telling the user what to do) as we can now install as non-root.
>
> Ugh. That would mean I can type stuff like sperl to install a suid
> binary (security problem).
Valid point.
> I don't think the whole feature would be
> all that useful. Your casual Jane User is very unlikely to launch a
> terminal and type stuff like "firefox" while an admin would certainly
> just install apache instead of typing "apachectl" and waiting for the
> shell to install random pieces of software.
Also a valid point. Maybe suggesting software might be the best thing to
do in this case.
Richard.
More information about the PackageKit
mailing list