From: Eric Wong <mwrap-public@80x24.org>
To: mwrap-public@80x24.org
Subject: [PATCH] various doc updates
Date: Mon, 22 Aug 2022 18:09:08 +0000 [thread overview]
Message-ID: <20220822180908.22203-1-mwrap-public@80x24.org> (raw)
Copyright years are unnecessary churn and probably aren't
necessary:
https://www.linuxfoundation.org/blog/copyright-notices-in-open-source-software-projects/
add POP3 and IMAP archive info, and drop the outdated link
to the live demo since I no longer have the resources to run it.
Finally, add rdoc (olddoc) + rsync support
---
.document | 1 +
.gitignore | 3 +++
.olddoc.yml | 4 +++-
README | 12 +++++++-----
Rakefile | 30 +++++++++++++++++++++++++++++-
bin/mwrap | 2 +-
ext/mwrap/extconf.rb | 2 +-
ext/mwrap/mwrap.c | 2 +-
lib/mwrap_rack.rb | 8 +++-----
test/test_mwrap.rb | 2 +-
10 files changed, 50 insertions(+), 16 deletions(-)
diff --git a/.document b/.document
index 4ca33e3..4385cfe 100644
--- a/.document
+++ b/.document
@@ -1,2 +1,3 @@
ext/mwrap/mwrap.c
lib/mwrap_rack.rb
+README
diff --git a/.gitignore b/.gitignore
index aa3606c..f670b62 100644
--- a/.gitignore
+++ b/.gitignore
@@ -4,3 +4,6 @@
/pkg
/*.gem
/doc
+/NEWS
+/NEWS.atom.xml
+/LATEST
diff --git a/.olddoc.yml b/.olddoc.yml
index dac0353..bfecbaf 100644
--- a/.olddoc.yml
+++ b/.olddoc.yml
@@ -5,4 +5,6 @@ rdoc_url: https://80x24.org/mwrap/
ml_url: https://80x24.org/mwrap-public/
public_email: mwrap-public@80x24.org
nntp_url:
- - nntp://news.public-inbox.org/inbox.comp.lang.ruby.mwrap
+- nntps://news.public-inbox.org/inbox.comp.lang.ruby.mwrap
+imap_url:
+- imaps://;AUTH=ANONYMOUS@80x24.org/inbox.comp.lang.ruby.mwrap.0
diff --git a/README b/README
index 3a20258..f387bc4 100644
--- a/README
+++ b/README
@@ -67,16 +67,18 @@ first two columns to find the hottest malloc locations.
mwrap 2.0.0+ also supports a Rack application endpoint,
it is documented at:
- https://80x24.org/mwrap/MwrapRack.html
+https://80x24.org/mwrap/MwrapRack.html
== Known problems
* 32-bit machines are prone to overflow (WONTFIX)
-== Mail archives and list:
+== Public mail archives and contact info:
- https://80x24.org/mwrap-public/
- nntp://80x24.org/inbox.comp.lang.ruby.mwrap
+* https://80x24.org/mwrap-public/
+* nntps://80x24.org/inbox.comp.lang.ruby.mwrap
+* imaps://;AUTH=ANONYMOUS@80x24.org/inbox.comp.lang.ruby.mwrap.0
+* https://80x24.org/mwrap-public/_/text/help/#pop3
No subscription will ever be required to post, but HTML mail
will be rejected:
@@ -88,7 +90,7 @@ will be rejected:
git clone https://80x24.org/mwrap.git
Send all patches and pull requests (use "git request-pull" to format) to
-the mailing list. We do not use centralized or proprietary messaging
+mwrap-public@80x24.org. We do not use centralized or proprietary messaging
systems.
== License
diff --git a/Rakefile b/Rakefile
index 50bfa89..255d346 100644
--- a/Rakefile
+++ b/Rakefile
@@ -1,4 +1,4 @@
-# Copyright (C) 2018 mwrap hackers <mwrap-public@80x24.org>
+# Copyright (C) mwrap hackers <mwrap-public@80x24.org>
# License: GPL-2.0+ <https://www.gnu.org/licenses/gpl-2.0.txt>
require 'rake/testtask'
begin
@@ -14,3 +14,31 @@ task :default => :compile
c_files = File.readlines('MANIFEST').grep(%r{ext/.*\.[ch]$}).map!(&:chomp!)
task 'compile:mwrap' => c_files
+
+olddoc = ENV['OLDDOC'] || 'olddoc'
+rdoc = ENV['RDOC'] || 'rdoc'
+task :rsync_docs do
+ require 'fileutils'
+ top = %w(README COPYING LATEST NEWS NEWS.atom.xml)
+ system("git", "set-file-times")
+ dest = ENV["RSYNC_DEST"] || "80x24.org:/srv/80x24/mwrap/"
+ FileUtils.rm_rf('doc')
+ sh "#{olddoc} prepare"
+ sh "#{rdoc} -f dark216" # dark216 requires olddoc 1.7+
+ File.unlink('doc/created.rid') rescue nil
+ File.unlink('doc/index.html') rescue nil
+ FileUtils.cp(top, 'doc')
+ sh "#{olddoc} merge"
+
+ Dir['doc/**/*'].each do |txt|
+ st = File.stat(txt)
+ if st.file?
+ gz = "#{txt}.gz"
+ tmp = "#{gz}.#$$"
+ sh("gzip --rsyncable -9 <#{txt} >#{tmp}")
+ File.utime(st.atime, st.mtime, tmp) # make nginx gzip_static happy
+ File.rename(tmp, gz)
+ end
+ end
+ sh("rsync --chmod=Fugo=r #{ENV['RSYNC_OPT']} -av doc/ #{dest}/")
+end
diff --git a/bin/mwrap b/bin/mwrap
index 9f67dab..212078c 100755
--- a/bin/mwrap
+++ b/bin/mwrap
@@ -1,6 +1,6 @@
#!/usr/bin/ruby
# frozen_string_literal: true
-# Copyright (C) 2018 mwrap hackers <mwrap-public@80x24.org>
+# Copyright (C) mwrap hackers <mwrap-public@80x24.org>
# License: GPL-2.0+ <https://www.gnu.org/licenses/gpl-2.0.txt>
require 'mwrap'
mwrap_so = $".grep(%r{/mwrap\.so\z})[0] or abort "mwrap.so not loaded"
diff --git a/ext/mwrap/extconf.rb b/ext/mwrap/extconf.rb
index 254a3bb..512ab82 100644
--- a/ext/mwrap/extconf.rb
+++ b/ext/mwrap/extconf.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-# Copyright (C) 2018 mwrap hackers <mwrap-public@80x24.org>
+# Copyright (C) mwrap hackers <mwrap-public@80x24.org>
# License: GPL-2.0+ <https://www.gnu.org/licenses/gpl-2.0.txt>
require 'mkmf'
diff --git a/ext/mwrap/mwrap.c b/ext/mwrap/mwrap.c
index a097b2e..85b847b 100644
--- a/ext/mwrap/mwrap.c
+++ b/ext/mwrap/mwrap.c
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2018 mwrap hackers <mwrap-public@80x24.org>
+ * Copyright (C) mwrap hackers <mwrap-public@80x24.org>
* License: GPL-2.0+ <https://www.gnu.org/licenses/gpl-2.0.txt>
*/
#define _LGPL_SOURCE /* allows URCU to inline some stuff */
diff --git a/lib/mwrap_rack.rb b/lib/mwrap_rack.rb
index e45b26d..53380b9 100644
--- a/lib/mwrap_rack.rb
+++ b/lib/mwrap_rack.rb
@@ -1,4 +1,4 @@
-# Copyright (C) 2018 all contributors <mwrap@80x24.org>
+# Copyright (C) all contributors <mwrap-public@80x24.org>
# License: GPL-2.0+ <https://www.gnu.org/licenses/gpl-2.0.txt>
# frozen_string_literal: true
require 'mwrap'
@@ -17,9 +17,6 @@ require 'cgi'
# map('/MWRAP') { run(MwrapRack.new) }
# map('/') { run(your_normal_app) }
#
-# A live demo is available at https://80x24.org/MWRAP/
-# (warning the demo machine is 32-bit, so counters will overflow)
-#
# This module is only available in mwrap 2.0.0+
class MwrapRack
module HtmlResponse # :nodoc:
@@ -115,10 +112,11 @@ class MwrapRack
end
GC_STAT_URL = 'https://docs.ruby-lang.org/en/trunk/GC.html#method-c-stat'
- GC_STAT_HELP = <<~""
+ GC_STAT_HELP = <<~EOM
<p>Non-Infinity lifespans can indicate fragmentation.
<p>See <a
href="#{GC_STAT_URL}">#{GC_STAT_URL}</a> for info on GC.stat values.
+ EOM
def each
Mwrap.quiet do
diff --git a/test/test_mwrap.rb b/test/test_mwrap.rb
index c506554..eaa65cb 100644
--- a/test/test_mwrap.rb
+++ b/test/test_mwrap.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
-# Copyright (C) 2018 mwrap hackers <mwrap-public@80x24.org>
+# Copyright (C) mwrap hackers <mwrap-public@80x24.org>
# License: GPL-2.0+ <https://www.gnu.org/licenses/gpl-2.0.txt>
require 'test/unit'
require 'mwrap'
reply other threads:[~2022-08-22 18:09 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly 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: https://80x24.org/mwrap/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220822180908.22203-1-mwrap-public@80x24.org \
--to=mwrap-public@80x24.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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mwrap.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).