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

Bug#609162: debian-policy: package names with dots/periods ('.') and crontab files: packagers beware



user debian-policy@packages.debian.org
usertags 609162 + normative discussion
severity 609162 normal
quit

Hi Karl,

Karl E. Jorgensen wrote:

> The debian policy section 9.5 [1] suggests using the package name as a
> file name when creating files in /etc/cron.d, /etc/cron.hourly,
> /etc/cron.daily etc.  This works well *unless* the package name
> includes a dot ('.'), as this forces the file name to include a
> dot. And cron will ignore the files as a result.

Thanks for raising this.  I agree that we should change the advice

	If a certain job has to be executed at some other frequency or
	at a specific time, the package should install a file
	/etc/cron.d/<package>

to reflect the run-parts rule

	If neither the --lsbsysinit option nor the --regex option is
	given then the names must consist entirely of ASCII upper- and
	lower-case letters, ASCII digits, ASCII underscores, and ASCII
	minus-hyphens.

The current rule for package names (from §5.6.1) is

	[a-z0-9][-+a-z0-9.]+

so the problematic characters are dot ('.'), which you mentioned,
and plus ('+').

You proposed to advocate substituting hyphens for dots, but that
would create problems when the names of two packages differ only
by punctuation:

	great-package
	great.package

Maybe we don't have to worry about such an insane case.  In any event,
it's easy to avoid that problem by substituting underscores for dots
and P for plus signs.

Sensible?  If so, would you like to propose wording for this?

Regards,
Jonathan



Reply to: