From 1f12b6e89618b3bee30f830428cb1ea66924dc84 Mon Sep 17 00:00:00 2001 From: calvin Date: Sat, 10 Mar 2001 10:14:31 +0000 Subject: [PATCH] clean up Makefile git-svn-id: https://linkchecker.svn.sourceforge.net/svnroot/linkchecker/trunk/linkchecker@241 e7d03fd6-7b0d-0410-9947-9c21f3af8025 --- Makefile | 14 ++------------ debian/changelog | 3 --- linkcheck/__init__.py | 3 +++ linkcheck/timeoutsocket.py | 2 +- linkchecker.1 | 12 ++++++------ test/output/test_file | 29 +++++++++++++++++++++++++++++ 6 files changed, 41 insertions(+), 22 deletions(-) create mode 100644 test/output/test_file diff --git a/Makefile b/Makefile index d4e95205..4a8c02dd 100644 --- a/Makefile +++ b/Makefile @@ -8,8 +8,6 @@ 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 DEBPACKAGE = $(PACKAGE)_$(VERSION)_all.deb $(PACKAGE)-ssl_$(VERSION)_i386.deb -PULLHOST=phoenix.net.uni-sb.de -PULLPATH=/home/calvin/temp/linkchecker OFFLINETESTS = test_base test_misc test_file test_frames ONLINETESTS = test_mail test_http test_https test_news test_ftp @@ -62,19 +60,11 @@ upload: distclean dist package files VERSION scp dist/* shell1.sourceforge.net:/home/groups/ftp/pub/$(PACKAGE)/ ssh -C -t shell1.sourceforge.net "cd /home/groups/$(PACKAGE) && make" -uploadpull: distclean dist package files VERSION - # shit, need to make pull, scp upload is not working any more - # aha, sourceforge fixed the shells, use upload again :) - ssh -t $(PULLHOST) "cd $(PULLPATH) && make clean" - scp debian/changelog README linkchecker-out.* VERSION $(PULLHOST):$(PULLPATH) - scp dist/* $(PULLHOST):$(PULLPATH)/dist - ssh -C -t shell1.sourceforge.net "cd /home/groups/$(PACKAGE) && make pull" - test: - python2 test/regrtest.py $(OFFLINE_TESTS) + python2 test/regrtest.py $(OFFLINETESTS) onlinetest: - python2 test/regrtest.py $(ONLINE_TESTS) + python2 test/regrtest.py $(ONLINETESTS) locale: $(MAKE) -C po diff --git a/debian/changelog b/debian/changelog index a3919b1d..cc746fc9 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,13 +1,10 @@ linkchecker (1.3.0) unstable; urgency=low * require and use Python >= 2.0 - * fix agent matching in robotparser2.py - * added more LinkPatterns (ripped from HTML::Tagset.pm) * fix ignored configfile settings for loggers * optional filename argument for -F (patch from Jamie Heilman ) * config file option to control which fields the loggers should print - * fix anchor bug (unpack tuple of wrong size) -- Bastian Kleineidam Thu, 22 Feb 2001 01:35:50 +0100 diff --git a/linkcheck/__init__.py b/linkcheck/__init__.py index 8577bbbf..9dea844a 100644 --- a/linkcheck/__init__.py +++ b/linkcheck/__init__.py @@ -47,6 +47,9 @@ except ImportError: # set _ as an alias for gettext _ = gettext +import timeoutsocket +timeoutsocket.setDefaultSocketTimeout(20) + import Config,UrlData,sys,lc_cgi def checkUrls(config = Config.Configuration()): diff --git a/linkcheck/timeoutsocket.py b/linkcheck/timeoutsocket.py index 987c8c9e..4e0e93f8 100644 --- a/linkcheck/timeoutsocket.py +++ b/linkcheck/timeoutsocket.py @@ -1,4 +1,4 @@ -"""Timeout Socket +"""enables a timeout on all TCP connections This module enables a timeout mechanism on all TCP connections. It does this by inserting a shim on top of the socket module. After diff --git a/linkchecker.1 b/linkchecker.1 index afec5883..455703b2 100644 --- a/linkchecker.1 +++ b/linkchecker.1 @@ -1,4 +1,4 @@ -.TH LINKCHECKER 1 "18 November 2000" +.TH LINKCHECKER 1 "10 March 2001" .SH NAME linkchecker \- check your HTML documents for broken links .SH SYNOPSIS @@ -11,7 +11,7 @@ linkchecker \- check your HTML documents for broken links ] .SH DESCRIPTION .LP -LinkChecker features +linkchecker features recursive checking, multithreading, output in colored or normal text, HTML, SQL, CSV or a sitemap @@ -44,7 +44,7 @@ Assume urls that match the given regular expression as extern. Only intern HTML links are checked recursively. .TP \fB-f \fIfile\fP, \fB--config=\fIfile\fP -Use \fIfile\fP as configuration file. LinkChecker first searches for +Use \fIfile\fP as configuration file. linkchecker first searches for ~/.linkcheckerrc and then /etc/linkcheckerrc on Unix systems. Under Windows systems we read \\linkcheckerrc. .TP @@ -57,7 +57,7 @@ output. .TP \fB-i \fIregex\fP, \fB--intern=\fIregex\fP Assume URLs that match the given regular expression as intern. -LinkChecker descends recursively only to intern URLs, not to extern. +linkchecker descends recursively only to intern URLs, not to extern. .TP \fB-h\fP, \fB--help\fP Help me! Print usage information for this program. @@ -127,12 +127,12 @@ Use the -s and -i options to prevent this. Javascript links are currently ignored. -If your platform does not support threading, LinkChecker uses +If your platform does not support threading, linkchecker uses \fB-t0\fP. You can supply multiple user/password pairs in a configuration file. -Cookies are not accepted by LinkChecker. +Cookies are not accepted by linkchecker. To use proxies set $http_proxy, $https_proxy on Unix or Windows. On a Mac use the Internet Config. diff --git a/test/output/test_file b/test/output/test_file new file mode 100644 index 00000000..733f7852 --- /dev/null +++ b/test/output/test_file @@ -0,0 +1,29 @@ +test_file +url file:///home/calvin/projects/linkchecker/test/html/file.html +valid +url http.html +name relative url +valid +url http.html#isnix +name bad anchor +warning anchor #isnix not found +valid +url http.html#iswas +name good anchor +valid +url file:///etc/group +name good file +valid +url file://etc/group +name bad file +error +url file:/etc/group +cached +name good file +valid +url file:etc/group +name bad file +error +url file:/etc/ +name good dir +valid