user/dev discussion of public-inbox itself
 help / color / Atom feed
From: Eric Wong <e@80x24.org>
To: meta@public-inbox.org
Subject: [PATCH 6/9] doc: give txt files proper titles
Date: Thu,  9 May 2019 07:51:00 +0000
Message-ID: <20190509075103.27132-7-e@80x24.org> (raw)
In-Reply-To: <20190509075103.27132-1-e@80x24.org>

We can fix the redundant rule in include.mk which causes
make(1) on FreeBSD to complain; but HTML docs will likely
still require GNU make.
---
 Documentation/design_www.txt | 2 ++
 Documentation/hosted.txt     | 2 ++
 Documentation/include.mk     | 5 +++--
 Documentation/txt2pre        | 3 +--
 4 files changed, 8 insertions(+), 4 deletions(-)

diff --git a/Documentation/design_www.txt b/Documentation/design_www.txt
index cd715b2..f15a556 100644
--- a/Documentation/design_www.txt
+++ b/Documentation/design_www.txt
@@ -1,3 +1,5 @@
+PublicInbox::WWW (PSGI interface) design notes
+
 URL and anchor naming
 ---------------------
 
diff --git a/Documentation/hosted.txt b/Documentation/hosted.txt
index 42926d2..0b1fb92 100644
--- a/Documentation/hosted.txt
+++ b/Documentation/hosted.txt
@@ -1,3 +1,5 @@
+unofficially hosted mirrors at public-inbox.org
+
 In addition to eating our own dogfood at <https://public-inbox.org/meta/>,
 public-inbox.org hosts unofficial archives for several other projects
 as a service to their users and to further test our own software.
diff --git a/Documentation/include.mk b/Documentation/include.mk
index 02cbef3..9089e06 100644
--- a/Documentation/include.mk
+++ b/Documentation/include.mk
@@ -87,8 +87,9 @@ dtxt := $(addprefix Documentation/, $(dtxt)) $(mantxt)
 Documentation/standards.txt : Documentation/standards.perl
 	$(PERL) $< >$@+ && mv $@+ $@
 
-%.html: %.txt
-	TITLE="$(basename $(<F))" $(txt2pre)
+Documentation/%.html: Documentation/%.txt
+	$(txt2pre)
+
 %.html: %
 	$(txt2pre)
 
diff --git a/Documentation/txt2pre b/Documentation/txt2pre
index 4c4b2ca..9a81a24 100755
--- a/Documentation/txt2pre
+++ b/Documentation/txt2pre
@@ -11,8 +11,7 @@ use PublicInbox::Linkify;
 use PublicInbox::Hval qw(ascii_html);
 
 my $str = eval { local $/; <> };
-my $title = $ENV{TITLE};
-($title) = ($str =~ /\A([^\n]+)/) unless $title;
+my ($title) = ($str =~ /\A([^\n]+)/);
 $title = ascii_html($title);
 my $l = PublicInbox::Linkify->new;
 $str = $l->linkify_1($str);
-- 
EW


  parent reply index

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-09  7:50 [PATCH 0/9] install updates Eric Wong
2019-05-09  7:50 ` [PATCH 1/9] INSTALL: update with FreeBSD pkg names and reorder Eric Wong
2019-05-09  7:50 ` [PATCH 2/9] INSTALL: depend on Encode instead of Encode::MIME::Header Eric Wong
2019-05-09  7:50 ` [PATCH 3/9] INSTALL: note xapian-compact(1) tool Eric Wong
2019-05-09  7:50 ` [PATCH 4/9] t/purge.t: fix unreferenced variable Eric Wong
2019-05-09  7:50 ` [PATCH 5/9] doc: use bullet list for wwwlisting options Eric Wong
2019-05-09  7:51 ` Eric Wong [this message]
2019-05-09  7:51 ` [PATCH 7/9] Makefile.PL: improve make(1) portability Eric Wong
2019-05-09  7:51 ` [PATCH 8/9] doc/include.mk: remove git use and redundant declarations Eric Wong
2019-05-09  7:51 ` [PATCH 9/9] ci: include some scripts to make CI easier Eric Wong

Reply instructions:

You may reply publically to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://public-inbox.org/README

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190509075103.27132-7-e@80x24.org \
    --to=e@80x24.org \
    --cc=meta@public-inbox.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

user/dev discussion of public-inbox itself

Archives are clonable:
	git clone --mirror http://public-inbox.org/meta
	git clone --mirror http://czquwvybam4bgbro.onion/meta
	git clone --mirror http://hjrcffqmbrq6wope.onion/meta
	git clone --mirror http://ou63pmih66umazou.onion/meta

Example config snippet for mirrors

Newsgroups are available over NNTP:
	nntp://news.public-inbox.org/inbox.comp.mail.public-inbox.meta
	nntp://ou63pmih66umazou.onion/inbox.comp.mail.public-inbox.meta
	nntp://czquwvybam4bgbro.onion/inbox.comp.mail.public-inbox.meta
	nntp://hjrcffqmbrq6wope.onion/inbox.comp.mail.public-inbox.meta
	nntp://news.gmane.org/gmane.mail.public-inbox.general

 note: .onion URLs require Tor: https://www.torproject.org/

AGPL code for this site: git clone https://public-inbox.org/public-inbox.git