logger fixes

git-svn-id: https://linkchecker.svn.sourceforge.net/svnroot/linkchecker/trunk/linkchecker@240 e7d03fd6-7b0d-0410-9947-9c21f3af8025
This commit is contained in:
calvin 2001-03-04 19:42:35 +00:00
parent ff89ea2136
commit 4a0a95d71e
8 changed files with 29 additions and 34 deletions

5
FAQ
View file

@ -2,10 +2,7 @@ Q: LinkChecker produced an error, but my web page is ok with
Netscape/IE/Opera/...
Is this a bug in LinkChecker?
A: Please check your web pages first. Are they really ok? Use
a syntax highlighting Editor!! Use HTML Tidy!!!
Ah, this is a good idea, I will not debug ANY web pages
which produce any output with the official HTML validator
"HTML Tidy" from www.w3c.org.
a syntax highlighting Editor! Use HTML Tidy from www.w3c.org!
Check if the web server is accepting HEAD requests as well.

View file

@ -9,9 +9,6 @@ Python >= 2.0 from http://www.python.org/
Optionally packages
-------------------
OpenSSL from http://www.openssl.org/
You will need Perl for Win32 (available from
http://www.activestate.com/ActivePerl) if you want to install OpenSSL
on Windows!
Setup

View file

@ -1,10 +1,9 @@
# This Makefile is only used by developers.
# You will need a Debian Linux system to use this Makefile because
# some targets produce Debian .deb packages
PYTHON=python2.0
VERSION=$(shell $(PYTHON) setup.py --version)
PACKAGE = linkchecker
NAME = $(shell $(PYTHON) setup.py --name)
VERSION=$(shell ./setup.py --version)
PACKAGE=linkchecker
NAME=$(shell ./setup.py --name)
HOST=treasure.calvinsplayground.de
#LCOPTS=-ocolored -Ftext -Fhtml -Fgml -Fsql -Fcsv -Fxml -R -t0 -v -s
LCOPTS=-ocolored -Ftext -Fhtml -Fgml -Fsql -Fcsv -Fxml -R -t0 -v -s
@ -21,7 +20,7 @@ all:
@echo "Read the file INSTALL to see how to build and install"
clean:
-$(PYTHON) setup.py clean --all # ignore errors of this command
-./setup.py clean --all # ignore errors of this command
$(MAKE) -C po clean
find . -name '*.py[co]' | xargs rm -f
@ -35,15 +34,16 @@ cleandeb:
rm -f configure-stamp build-stamp
dist: locale
./setup.py sdist --formats=gztar,zip bdist_rpm
# extra run without SSL compilation
python setup.py bdist_wininst
deb:
# cleandeb because distutils choke on dangling symlinks
# (linkchecker.1 -> undocumented.1)
$(MAKE) cleandeb
fakeroot debian/rules binary
$(PYTHON) setup.py sdist --formats=gztar,zip bdist_rpm
# extra run without SSL compilation
python setup.py bdist_wininst
#fakeroot dpkg-buildpackage -sgpg -pgpg
mv -f ../$(DEBPACKAGE) dist
fakeroot dpkg-buildpackage -sgpg -pgpg -k959C340F
package:
cd dist && dpkg-scanpackages . ../override.txt | gzip --best > Packages.gz

4
debian/rules vendored
View file

@ -23,7 +23,7 @@ configure-stamp:
build: configure-stamp build-stamp
build-stamp:
dh_testdir
rm -rf debian/$(PACKAGE)
rm -rf debian/$(PACKAGE) debian/$(PACKAGE)-ssl
./setup.py build
touch build-stamp
@ -39,7 +39,7 @@ install: build
dh_installdirs
$(MAKE) locale
./setup.py install --root=`pwd`/debian/$(PACKAGE) --no-compile
# remove man pages, we install them with dh_installmanpages
# remove man pages, we install them with dh_installman
rm -rf debian/$(PACKAGE)/usr/man
# remove example files, we install them with dh_installexamples
rm -rf debian/$(PACKAGE)/usr/share/linkchecker

View file

@ -354,7 +354,7 @@ class ColoredLogger(StandardLogger):
if self.currentPage != urlData.parentName:
if self.prefix:
self.fd.write("o\n")
self.fd.write("\n"+_("Parent URL")+Spaces["Parent URL"]+
self.fd.write("\n"+_("Parent URL")+Spaces["parenturl"]+
self.colorparent+urlData.parentName+
self.colorreset+"\n")
self.currentPage = urlData.parentName
@ -369,7 +369,7 @@ class ColoredLogger(StandardLogger):
self.fd.write("|\n+- ")
else:
self.fd.write("\n")
self.fd.write(_("URL")+Spaces["URL"]+self.colorurl+urlData.urlName+
self.fd.write(_("URL")+Spaces["url"]+self.colorurl+urlData.urlName+
self.colorreset)
if urlData.line: self.fd.write(_(", line ")+`urlData.line`+"")
if urlData.cached:
@ -380,52 +380,52 @@ class ColoredLogger(StandardLogger):
if urlData.name:
if self.prefix:
self.fd.write("| ")
self.fd.write(_("Name")+Spaces["Name"]+self.colorname+
self.fd.write(_("Name")+Spaces["name"]+self.colorname+
urlData.name+self.colorreset+"\n")
if urlData.baseRef:
if self.prefix:
self.fd.write("| ")
self.fd.write(_("Base")+Spaces["Base"]+self.colorbase+
self.fd.write(_("Base")+Spaces["base"]+self.colorbase+
urlData.baseRef+self.colorreset+"\n")
if urlData.url:
if self.prefix:
self.fd.write("| ")
self.fd.write(_("Real URL")+Spaces["Real URL"]+self.colorreal+
self.fd.write(_("Real URL")+Spaces["realurl"]+self.colorreal+
urlData.url+self.colorreset+"\n")
if urlData.downloadtime:
if self.prefix:
self.fd.write("| ")
self.fd.write(_("D/L Time")+Spaces["D/L Time"]+self.colordltime+
self.fd.write(_("D/L Time")+Spaces["dltime"]+self.colordltime+
(_("%.3f seconds") % urlData.downloadtime)+self.colorreset+"\n")
if urlData.checktime:
if self.prefix:
self.fd.write("| ")
self.fd.write(_("Check Time")+Spaces["Check Time"]+
self.fd.write(_("Check Time")+Spaces["checktime"]+
self.colordltime+
(_("%.3f seconds") % urlData.checktime)+self.colorreset+"\n")
if urlData.infoString:
if self.prefix:
self.fd.write("| "+_("Info")+Spaces["Info"]+
self.fd.write("| "+_("Info")+Spaces["info"]+
StringUtil.indentWith(StringUtil.blocktext(
urlData.infoString, 65), "| "+Spaces["Info"]))
urlData.infoString, 65), "| "+Spaces["info"]))
else:
self.fd.write(_("Info")+Spaces["Info"]+
self.fd.write(_("Info")+Spaces["info"]+
StringUtil.indentWith(StringUtil.blocktext(
urlData.infoString, 65), " "+Spaces["Info"]))
urlData.infoString, 65), " "+Spaces["info"]))
self.fd.write(self.colorreset+"\n")
if urlData.warningString:
self.warnings += 1
if self.prefix:
self.fd.write("| ")
self.fd.write(_("Warning")+Spaces["Warning"]+self.colorwarning+
self.fd.write(_("Warning")+Spaces["warning"]+self.colorwarning+
urlData.warningString+self.colorreset+"\n")
if self.prefix:
self.fd.write("| ")
self.fd.write(_("Result")+Spaces["Result"])
self.fd.write(_("Result")+Spaces["result"])
if urlData.valid:
self.fd.write(self.colorvalid+urlData.validString+
self.colorreset+"\n")

View file

@ -155,4 +155,4 @@ linkchecker www.myhomepage.de
.br
linkchecker -r0 ftp.linux.org\fP
.SH AUTHOR
Bastian Kleineidam <calvin@users.sourceforge.net>
Bastian Kleineidam <calvin@debian.org>

View file

@ -98,7 +98,7 @@ threads=5
anchors=0
recursionlevel=1
# obey robots.txt exclusion?
robotstxt=1
robotstxt=0
# overall strict checking. You can specify for each extern URL
# separately if its strict or not. See the [filtering] section
strict=0

View file

@ -134,6 +134,7 @@ class MyConfig(config):
def run (self):
# try to compile a test program with SSL
config.run(self)
self.libraries.append('ssl')
have_ssl = self.check_lib("ssl",
library_dirs = self.ssl_library_dirs,
include_dirs = self.ssl_include_dirs,