mirror of
https://github.com/Hopiu/linkchecker.git
synced 2026-05-17 19:11:06 +00:00
pychecker fixes
git-svn-id: https://linkchecker.svn.sourceforge.net/svnroot/linkchecker/trunk/linkchecker@364 e7d03fd6-7b0d-0410-9947-9c21f3af8025
This commit is contained in:
parent
cb47dcecdd
commit
e6e38295d7
6 changed files with 26 additions and 34 deletions
34
Makefile
34
Makefile
|
|
@ -13,54 +13,51 @@ OFFLINETESTS = test_base test_misc test_file test_frames
|
|||
ONLINETESTS = test_mail test_http test_https test_news test_ftp
|
||||
DESTDIR=/.
|
||||
|
||||
.PHONY: all
|
||||
all:
|
||||
@echo "Read the file INSTALL to see how to build and install"
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
-$(PYTHON) setup.py clean --all # ignore errors of this command
|
||||
$(MAKE) -C po clean
|
||||
find . -name '*.py[co]' | xargs rm -f
|
||||
|
||||
.PHONY: distclean
|
||||
distclean: clean cleandeb
|
||||
rm -rf dist build # just to be sure clean also the build dir
|
||||
rm -f VERSION _$(PACKAGE)_configdata.py MANIFEST Packages.gz
|
||||
# clean aborted dist builds and -out files
|
||||
rm -f $(PACKAGE)-*
|
||||
|
||||
.PHONY: cleandeb
|
||||
cleandeb:
|
||||
rm -rf debian/$(PACKAGE) debian/tmp
|
||||
rm -f debian/*.debhelper debian/{files,substvars}
|
||||
rm -f configure-stamp build-stamp
|
||||
|
||||
.PHONY: config
|
||||
config:
|
||||
$(PYTHON) setup.py config -lcrypto
|
||||
|
||||
# no rpm package; too much trouble, cannot test
|
||||
.PHONY: dist
|
||||
dist: locale config
|
||||
$(PYTHON) setup.py sdist --formats=gztar,zip bdist_wininst
|
||||
|
||||
deb:
|
||||
# cleandeb because distutils choke on dangling symlinks
|
||||
# (linkchecker.1 -> undocumented.1)
|
||||
$(MAKE) cleandeb
|
||||
# produce the .deb Debian package
|
||||
deb_local: cleandeb
|
||||
# standard for local use
|
||||
fakeroot debian/rules binary
|
||||
env CVSROOT=:pserver:anonymous@cvs.linkchecker.sourceforge.net:/cvsroot/linkchecker cvs-buildpackage -Mlinkchecker -W/home/calvin/projects/cvs-build -sgpg -pgpg -k32EC6F3E -rfakeroot
|
||||
#env CVSROOT=:pserver:anonymous@cvs.linkchecker.sourceforge.net:/cvsroot/linkchecker cvs-buildpackage -Mlinkchecker -W/home/calvin/projects/cvs-build -us -uc -rfakeroot
|
||||
|
||||
.PHONY: files
|
||||
deb_signed: cleandeb
|
||||
# ready for upload, signed with my GPG key
|
||||
env CVSROOT=:pserver:anonymous@cvs.linkchecker.sourceforge.net:/cvsroot/linkchecker cvs-buildpackage -Mlinkchecker -W/home/calvin/projects/cvs-build -sgpg -pgpg -k32EC6F3E -rfakeroot
|
||||
|
||||
deb_unsigned: cleandeb
|
||||
# same thing, but unsigned (for local archives)
|
||||
env CVSROOT=:pserver:anonymous@cvs.linkchecker.sourceforge.net:/cvsroot/linkchecker cvs-buildpackage -Mlinkchecker -W/home/calvin/projects/cvs-build -us -uc -rfakeroot
|
||||
|
||||
files: locale
|
||||
env http_proxy="" $(PYTHON) $(PACKAGE) $(LCOPTS) -i$(HOST) http://$(HOST)/
|
||||
|
||||
VERSION:
|
||||
echo $(VERSION) > VERSION
|
||||
|
||||
.PHONY: upload
|
||||
upload: distclean dist files VERSION
|
||||
scp debian/changelog $(HTMLDIR)/changes.txt
|
||||
scp README $(HTMLDIR)/readme.txt
|
||||
|
|
@ -69,18 +66,17 @@ upload: distclean dist files VERSION
|
|||
scp dist/* $(HTMLDIR)/
|
||||
ssh -C -t shell1.sourceforge.net "cd $(PACKAGEDIR) && make"
|
||||
|
||||
.PHONY: test
|
||||
test:
|
||||
$(PYTHON) test/regrtest.py $(OFFLINETESTS)
|
||||
|
||||
.PHONY: onlinetest
|
||||
onlinetest:
|
||||
$(PYTHON) test/regrtest.py $(ONLINETESTS)
|
||||
|
||||
.PHONY: locale
|
||||
locale:
|
||||
$(MAKE) -C po
|
||||
|
||||
.PHONY: timeouttest
|
||||
timeouttest:
|
||||
$(PYTHON) $(PACKAGE) -DDD --timeout=2 mailto:calvin@cs.uni-sb.de
|
||||
$(PYTHON) $(PACKAGE) -v --timeout=0 mailto:root@aol.com
|
||||
|
||||
.PHONY: all clean cleandeb distclean files upload test timeouttest locale
|
||||
.PHONY: onlinetest config dist deb_local deb_signed deb_unsigned
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@
|
|||
# IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
#
|
||||
|
||||
import re, string, types, UserList
|
||||
import string, types, UserList
|
||||
|
||||
|
||||
###################################################################################################
|
||||
|
|
@ -50,10 +50,9 @@ class CSV(UserList.UserList):
|
|||
Arguments:
|
||||
separator : The field delimiter. Defaults to ','
|
||||
"""
|
||||
|
||||
UserList.UserList.__init__(self)
|
||||
self.separator = separator
|
||||
|
||||
self.data = []
|
||||
self.fields__title__have = self.fields__title = None
|
||||
|
||||
|
||||
|
|
@ -381,8 +380,8 @@ class Entry(UserList.UserList):
|
|||
fields__title : a list with the titles of each field
|
||||
(an empty list means there are no titles)
|
||||
"""
|
||||
UserList.UserList.__init__(self, fields)
|
||||
|
||||
self.data = fields
|
||||
if fields__title != None:
|
||||
self.fields__title = fields__title
|
||||
else:
|
||||
|
|
|
|||
|
|
@ -57,6 +57,7 @@ ExcList = [
|
|||
ValueError, # from httplib.py
|
||||
linkcheck.error,
|
||||
DNS.Error,
|
||||
linkcheck.timeoutsocket.Timeout,
|
||||
]
|
||||
try:
|
||||
import socket
|
||||
|
|
@ -348,10 +349,6 @@ class UrlData:
|
|||
not self.extern
|
||||
|
||||
|
||||
def isHtml(self):
|
||||
return 0
|
||||
|
||||
|
||||
def checkAnchors(self, anchor):
|
||||
if not (anchor!="" and self.isHtml() and self.valid):
|
||||
return
|
||||
|
|
|
|||
|
|
@ -17,6 +17,7 @@
|
|||
|
||||
import re,time,urlparse
|
||||
from linkcheck import _
|
||||
from types import StringType
|
||||
|
||||
_logfile = None
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ __version__ = "v0.8 19/10/1998 ajung"
|
|||
__doc__ = "Multithreaded FastCGI Wrapper"
|
||||
|
||||
|
||||
import sys,thread,fcgi
|
||||
import thread,fcgi
|
||||
|
||||
class SZ_FCGI:
|
||||
def __init__(self,func):
|
||||
|
|
|
|||
|
|
@ -18,6 +18,7 @@
|
|||
import sys,time,rotor,types
|
||||
|
||||
_curses = None
|
||||
_color = 0
|
||||
try:
|
||||
from ncurses import curses
|
||||
_curses = curses
|
||||
|
|
@ -74,7 +75,7 @@ def abbuzze():
|
|||
my,mx = w.getmaxyx()
|
||||
b = w.subwin(my-2, mx, 0, 0)
|
||||
s = w.subwin(2, mx, my-2, 0)
|
||||
if color:
|
||||
if _color:
|
||||
s.color_set(1)
|
||||
bs = nassmache(_bs)
|
||||
ss = nassmache(_ss)
|
||||
|
|
@ -92,12 +93,12 @@ def abbuzze():
|
|||
_curses.endwin()
|
||||
|
||||
def config_curses():
|
||||
global _color
|
||||
_curses.nonl() # tell curses not to do NL->CR/NL on output
|
||||
_curses.noecho() # don't echo input
|
||||
_curses.cbreak() # take input chars one at a time, no wait for \n
|
||||
global color
|
||||
if hasattr(_curses, "start_color"):
|
||||
color = 1
|
||||
if hasattr(_curses, "start_color") and hasattr(_curses, "set_color"):
|
||||
_color = 1
|
||||
_curses.start_color() # start the colour system
|
||||
if _curses.has_colors():
|
||||
if _curses.can_change_color():
|
||||
|
|
@ -107,8 +108,6 @@ def config_curses():
|
|||
_curses.init_pair(2, curses.COLOR_MAGENTA, curses.COLOR_BLACK)
|
||||
_curses.init_pair(3, curses.COLOR_MAGENTA, curses.COLOR_BLACK)
|
||||
_curses.init_pair(4, curses.COLOR_MAGENTA, curses.COLOR_BLACK)
|
||||
else:
|
||||
color = 0
|
||||
|
||||
def waddemol(f):
|
||||
time.sleep(float(f))
|
||||
|
|
|
|||
Loading…
Reference in a new issue