Help > Cards: The Package Manager

[suggestion] add a type of dir field to the dir lines of cards.conf

(1/2) > >>

I think part of the problem why cards depcreate packageName results in segmentation faults if cards.conf contains lines like
dir var/lib/pkg/depot/collectionName
is that cards get confused between ports directories and binary packages directories.

The solution would be simple, add a type field to the dir lines.

I think most /etc/cards.conf files should looks like:
#url apply only to dir of type binary packages

dir b /var/lib/pkg/depot/base
dir b /var/lib/pkg/depot/cli
dir b /var/lib/pkg/depot/cli-extra
dir b /var/lib/pkg/depot/gui
dir b /var/lib/pkg/depot/gui-extra
dir b /var/lib/pkg/depot/desktops

dir p /usr/ports/base
dir p /usr/ports/cli
dir p /usr/ports/cli-extra
dir p /usr/ports/gui
dir p /usr/ports/gui-extra
dir p /usr/ports/desktops
dir p /usr/ports/personal

maybe it could be summarize to:
url b
basedir p /usr/ports
basedir b /var/lib/pkg/depot
collections b base,cli,cli-extra,gui,gui-extra,desktops
collections p base,cli,cli-extra,gui,gui-extra,desktops,personal

I have nothing against improving my baby cards tool, but I suggest you to (re)read the man of cards.conf first:

--- Code: ---man cards.conf
--- End code ---

Then we can discuss again

Oh, yeah...

So mistake #1: the format is: key value
so that adding a field between the key and the value is not fine

Mistake #2: there is already a proposed key for port directory: prtdir ... hum I thought it was portdir, I prefer portdir, so I will keep portdir

Mistake #3: order is important, personal directory should come first to be used first, before the others

Mistake #4: it is not depot it's repo It is really depot in 11.2.

So the first suggestion should look more like:

What should probably be a current /etc/cards.conf file (although not working for now):

--- Code: ---url

dir /var/lib/pkg/depot/desktops
#keep gui-extra before gui, in case a package with same name, but more functionality than in gui, is in gui-extra
dir /var/lib/pkg/depot/gui-extra
dir /var/lib/pkg/depot/gui
dir /var/lib/pkg/depot/cli-extra
dir /var/lib/pkg/depot/cli
dir /var/lib/pkg/depot/base

#keep personal first, because if you have same port also in other collections, you want yours to be used
portdir /usr/ports/personal
portdir /usr/ports/desktops
portdir /usr/ports/gui-extra
portdir /usr/ports/gui
portdir /usr/ports/cli-extra
portdir /usr/ports/cli
portdir /usr/ports/base

logdir /var/log/pkgbuild

group man
group devel

--- End code ---

 >:( >:( >:(  It's still wrong in the man. I will need to double check that.

So forget about prtdir. The only way needed for cards to know if it's a binary collection or a ports collection is by checking if they is an "url attached" to it or not. You mixt both but then you need to build via scenario E or via the build-collection tool


[0] Message Index

[#] Next page

Go to full version