Newsgroups: fj.editor.emacs
Path: galaxy.trc.rwcp.or.jp!jaist-news!cs.titech!wnoc-tyo-news!sh.wide!kogwy!cs-keio!itojun
From: itojun@mt.cs.keio.ac.jp (Jun-ichiro ITOH)
Subject: Re: Distribution (Re: Hikkosi, Re: sinkannsen)
In-Reply-To: onono@kado.elec.waseda.ac.jp's message of 15 Mar 93 21:26:44 JST
Message-ID: <ITOJUN.93Mar15220419@ingram.mt.cs.keio.ac.jp>
Sender: news@sync.cs.keio.ac.jp
Nntp-Posting-Host: ingram.mt.cs.keio.ac.jp
Organization: Tokoro Laboratory, Keio University, Yokohama Japan.
References: <KUROKI.93Mar8042020@tsuru.math.tohoku.ac.jp>
	<UMERIN.93Mar15194244@orchid.mse.kyutech.ac.jp>
	<ONONO.93Mar15212644@shuni.kado.elec.waseda.ac.jp>
Distribution: fj
Date: Mon, 15 Mar 1993 13:04:19 GMT
Lines: 127
Xref: galaxy.trc.rwcp.or.jp fj.editor.emacs:3594
X-originally-archived-at: http://galaxy.rwcp.or.jp/text/cgi-bin/newsarticle2?ng=fj.editor.emacs&nb=3594&hd=a
X-reformat-date: Mon, 18 Oct 2004 15:18:22 +0900
X-reformat-comment: Tabs were expanded into 4 column tabstops by the Galaxy's archiver. See http://katsu.watanabe.name/ancientfj/galaxy-format.html for more info.

$B$$$H$B$e$s(B@$B7DXfLp>e$G$9!#(B
#Followup-to: $B$OL5;k$7$F!"(Bfj.editor.emacs$B$NJ}$KB3$1$^$9!#(B
#$B$4$a$s$J$5$$!#(B

$B<B$N$H$3$m(B3.14.4$B$O$^$@8+$F$J$$$N$G$9$,!"$\$/$O(B3.14.1$B$G(B
$B$3$s$J$3$H$7$F$^$9!"$H$$$&$3$H$G!#(B

$B$b$7$J$s$+4*0c$$$7$F$?$i65$($F$/$@$5$$!#(B

On 15 Mar 93 21:26:44 JST, onono@kado.elec.waseda.ac.jp (ONO Kouichi) said:

> 3.14.4$B$G$O(B, $B%7%9%F%`Dj5A$N(B distributions $B$+$iA*Br;R$r<h$C$FMh$^$9(B.
> gnus-local-distributions $B$r@_Dj$9$k$3$H$G(B, $B99$K9%$_$N$b$N$rDI2C$9$k$3(B
> $B$H$,$G$-$^$9(B.
($BCfN,(B)
onono> Newsgroups: $B$GF~NO$7$?%0%k!<%WL>$N(B top $B$,(B 
onono> gnus-distribution-list $B$NCf$K$"$C$?$i!"$=$l$r(B 
onono> Distribution: $B$N%G%U%)%k%H$K$9$k!"$H$+$$$&$N$O$I$&$G$7$g(B
onono> $B$&$+!#(B

$BH/A[$O$3$l$H$*$J$8$G!"(BNewsgroups: $B$GF~NO$5$l$?%K%e!<%9%0%k!<%WL>$+$i(B
Distribution: $B$NL>A0$rD4$Y!"$b$78uJd$,$"$C$?$i$=$l$r:NMQ$9$k!"(B
$B$H$$$&$3$H$r$d$C$F$$$^$9!#(B

(setq gnus-default-distribution-alist
  '(("mt" . "mt")
    ("keio" . "keio")
    ("keio-cs" . "keio-cs")
    ("sfc" . "sfc")
    ("fj.test" . "local")
    ("fj" . "fj")
    ("control" . "local")
    ("general" . "local")
    ("DEFAULT" . "world")))

$B$H$$$&$h$&$J@_Dj$r$7$F$*$/$H!"(Bmt.nantara$B$K%]%9%H$9$k$H$-$O(B
Distribution: $B$,(Bmt$B$K(B....$B$H$$$&Iw$K=g<!8!:w$7$F$$$C$F!"(B
$B$O$:$l$@$C$?$i(Bworld$B$K$J$k$h$&$K$J$C$F$$$^$9!#(B

$B$$$+$,$G$7$g$&$+(B?

---$B$Q$C$A$3$3$+$i(B
*** /usr/local/lib/emacs/lisp/gnuspost.elSat May 18 23:30:43 1991
--- gnuspost.elWed Dec 23 15:04:59 1992
***************
*** 29,34 ****
--- 29,37 ----
  (defvar gnus-post-news-buffer "*post-news*")
  (defvar gnus-winconf-post-news nil)
  
+ ;; by itojun
+ (defvar gnus-default-distribution-alist nil)
+ 
  (autoload 'news-reply-mode "rnewspost")
  (autoload 'timezone-make-date-arpa-standard "timezone")
  
***************
*** 173,188 ****
  (setq subject (read-string "Subject: "))
  (setq distribution
        (substring newsgroups 0 (string-match "\\." newsgroups)))
! (if (string-equal distribution newsgroups)
!     ;; Newsgroup may be general or control. In this
!     ;; case, use default distribution.
!     (setq distribution gnus-default-distribution))
! (setq distribution
!       (read-string "Distribution: " distribution))
  ;; An empty string is ok to ignore gnus-default-distribution.
  ;;(if (string-equal distribution "")
  ;;    (setq distribution nil))
! ))
    (news-setup () subject () newsgroups artbuf)
    ;; Make sure the article is posted by GNUS.
    ;;(mail-position-on-field "Posting-Software")
--- 176,201 ----
  (setq subject (read-string "Subject: "))
  (setq distribution
        (substring newsgroups 0 (string-match "\\." newsgroups)))
! ;(if (string-equal distribution newsgroups)
! ;    ;; Newsgroup may be general or control. In this
! ;    ;; case, use default distribution.
! ;    (setq distribution gnus-default-distribution))
! ;; by itojun
! (if (and newsgroups gnus-default-distribution-alist)
!     (setq distribution (gnus-distribution-by-alist 
! newsgroups
! distribution)))
! ;(setq distribution
! ;      (read-string "Distribution: " distribution))
  ;; An empty string is ok to ignore gnus-default-distribution.
  ;;(if (string-equal distribution "")
  ;;    (setq distribution nil))
! )
! ;; by itojun
!       ;; when non-interactive mode, we still can use it
!       (if (and newsgroups gnus-default-distribution-alist)
!   (setq distribution (gnus-distribution-by-alist
!       newsgroups))))
    (news-setup () subject () newsgroups artbuf)
    ;; Make sure the article is posted by GNUS.
    ;;(mail-position-on-field "Posting-Software")
***************
*** 718,720 ****
--- 731,747 ----
        (goto-char (point-min))
        (search-forward "\n\n" nil 'move)
        (int-to-string (count-lines (point) (point-max))))))
+ 
+ ;; by itojun
+ (defun gnus-distribution-by-alist (newsgroups &optional default-distribution)
+   (or (cdr (assoc newsgroups
+   gnus-default-distribution-alist))
+       (cdr (assoc (substring newsgroups
+      0
+      (string-match "\\." newsgroups))
+   gnus-default-distribution-alist))
+       default-distribution
+       (cdr (assoc "DEFAULT"
+   gnus-default-distribution-alist))
+       gnus-default-distribution
+       ))
---$B$Q$C$A$3$3$^$G(B
--
$B$$$H$B$e$s(B@mt.cs.keio.ac.jp($B0KF#=c0lO:(B)
$B7DXf5A=NBg3XM}9)3XIt(B $BEE5$9)3X2J(B/$B8&5f2J7W;;5!2J3X@l96(B $B=j8&5f<<(B
itojun@mt.cs.keio.ac.jpitojun@foretune.co.jp
jinNet itojunESD/$B%(%s%2%k78?t8~>e0Q0w2q%=%U%H%&%'%"J,2J2q(B
