diff options
author | Eric Wong <e@80x24.org> | 2019-12-01 10:50:19 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2019-12-11 08:11:36 +0000 |
commit | 73fe3421f1ecbdc83600d5acfc643c33dbb9a0f2 (patch) | |
tree | 0d302ab79723662ef05a6718570c43f28328702d /Documentation/txt2pre | |
parent | 08f57606beaa3772aefd7ebde43e615781976678 (diff) | |
download | public-inbox-73fe3421f1ecbdc83600d5acfc643c33dbb9a0f2.tar.gz |
We can replace the GNU-isms for building docs with Perl5 equivalents. The only downside is the resulting Makefile gets larger, but that's the price of portability.
Diffstat (limited to 'Documentation/txt2pre')
-rwxr-xr-x | Documentation/txt2pre | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Documentation/txt2pre b/Documentation/txt2pre index 6f2a8c8a..7cab0fa2 100755 --- a/Documentation/txt2pre +++ b/Documentation/txt2pre @@ -22,3 +22,9 @@ print '<html><head>', qq(<meta\nhttp-equiv="Content-Type"\ncontent="text/html; charset=utf-8"\n/>), "<title>$title</title>", "</head><body><pre>", $str , '</pre></body></html>'; + +# keep mtime on website consistent so clients can cache +if (-f STDIN && -f STDOUT) { + my @st = stat(STDIN); + utime($st[8], $st[9], \*STDOUT); +} |