Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 8 Dec 1995 00:37:36 +0000
From:      mark@linus.demon.co.uk (Mark Valentine)
To:        Poul-Henning Kamp <phk@freefall.freebsd.org>, joerg_wunsch@uriah.heep.sax.de, freebsd-bugs@freefall.freebsd.org
Subject:   Re: gnu/231
Message-ID:  <199512080037.AAA01455@linus.demon.co.uk>
In-Reply-To: Poul-Henning Kamp's message of Dec  1,  3:16am

next in thread | raw e-mail | index | archive | help
> From: Poul-Henning Kamp <phk@freefall.freebsd.org>
> Date: Fri 1 Dec, 1995
> Subject: Re: gnu/231

> Synopsis: send-pr initializes Organization with ~/.signature
> 
> State-Changed-From-To: open-closed
> State-Changed-By: phk
> State-Changed-When: Fri Dec 1 03:16:04 PST 1995
> State-Changed-Why: 
> Nobody has any better idea, so it may not be right, but it is the best
> we can do.

Hmm.  I just got bit by this when I gave myself a .signature.  Before that,
send-pr correctly used $ORGANIZATION_C='<Organization of PR author (multiple
lines)>' to remind me to either fill it in or delete the line (I don't have
an organisation - I already had to hack trn not to fail because of that!).

It is incorrect to use random junk from .signature for this.  Just delete
the two lines in question and send-pr does more or less the right thing.

However, send-pr doesn't do the rest using quite the algorithm I know from
other programs either.  How about something like:

    1.  If $ORGANIZATION is set, use it.

    1a. Otherwise, if $ORGANISATION is set, use it.

    2.  If neither variable is set, and $DEFAULT_ORGANIZATION has been
	configured in send-pr.sh, use that.

    3.  In any case, if the value of any of these variables starts with /
	or ~, treat it as a file and use the contents of that file.  (For
	those who setenv ORGANIZATION ~/.organisation.)

    4.  If none of these variables are set, and ~/.organization or
	~/.organisation exists, use its contents.  (Note: don't do this
	if either $ORGANIZATION or $ORGANISATION was found and was set
	empty, but do if $DEFAULT_ORGANIZATION is set empty.)

    5.  Otherwise, let the later code fall back to $ORGANIZATION_C.

Other variations are acceptable, such as ignoring the correctly spelled
alternatives [some Canadian news transport authors would support me here,
though ;-) ], or using application-specific variables or files (equivalents
to $NEWSORGANIZATION? and /usr/lib/news/organization at the appropriate
points).  The ~/.organization probably isn't "standard" (it's redundant
anyway).

(DEFAULT_ORGANIZATION=/etc/organization is a good idea for some sites.)

		Mark (whose organisation, if it existed, probably wouldn't
		      have anything to do with tigers or tuna fish).

-- 
"Tigers will do ANYTHING for a tuna fish sandwich."
"We're kind of stupid that way."   *munch* *munch*



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199512080037.AAA01455>