diff --git a/ChangeLog b/ChangeLog index 8b15215f..ddc3b078 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,4 @@ -2.8 "" (released xx.xx.xxxx) +2.8 "Robots" (released 8.4.2005) * Correct AttributeError in blacklist logger. Type: bugfix @@ -15,6 +15,11 @@ Type: feature Changed: setup.py, install-linkchecker.py, doc/en/index.txt + * Use pydoc.pager() in strformat.paginate() instead of rolling out + our own paging algorithm. + Type: feature + Changed: linkcheck/strformat.py + 2.7 "Million Dollar Baby" (released 30.3.2005) * When a host has no MX record, fall back to A records as the mail diff --git a/TODO b/TODO index 6551a285..74a05645 100644 --- a/TODO +++ b/TODO @@ -23,4 +23,3 @@ Possible improvements people could work on: - [BUGFIX] CGI parameters should also be splitted on semicolons, but the join routine must also use semicolons then where apropriate. - \ No newline at end of file diff --git a/linkcheck/strformat.py b/linkcheck/strformat.py index 3f94796d..121eb9fc 100644 --- a/linkcheck/strformat.py +++ b/linkcheck/strformat.py @@ -25,6 +25,7 @@ import sys import os import time import urlparse +import pydoc def unicode_safe (s, encoding="iso-8859-1"): @@ -124,19 +125,11 @@ def get_line_number (s, index): return line -def paginate (text, lines=22): +def paginate (text): """ Print text in pages of lines. """ - curline = 1 - for line in text.splitlines(): - print line - curline += 1 - isatty = hasattr(sys.stdin, "isatty") and sys.stdin.isatty() - if curline >= lines and isatty: - curline = 1 - print "press return to continue..." - sys.stdin.read(1) + pydoc.pager(text) _markup_re = re.compile("<.*?>", re.DOTALL) diff --git a/po/linkchecker.pot b/po/linkchecker.pot index f090c699..014ebde7 100644 --- a/po/linkchecker.pot +++ b/po/linkchecker.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: calvin@users.sourceforge.net\n" -"POT-Creation-Date: 2005-04-01 11:24+0200\n" +"POT-Creation-Date: 2005-04-07 15:39+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -621,15 +621,15 @@ msgstr "" msgid "extern%d: syntax error %s\n" msgstr "" -#: ../linkcheck/strformat.py:188 +#: ../linkcheck/strformat.py:181 msgid "seconds" msgstr "" -#: ../linkcheck/strformat.py:191 +#: ../linkcheck/strformat.py:184 msgid "minutes" msgstr "" -#: ../linkcheck/strformat.py:194 +#: ../linkcheck/strformat.py:187 msgid "hours" msgstr ""