From: Wolfgang Bangerth Date: Wed, 16 Feb 2000 12:44:12 +0000 (+0000) Subject: Add a script that validates whether cross-references in out documentation are valid... X-Git-Tag: v8.0.0~20947 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cec5e66ae1722c789ca83d3c69f9090101ac88f5;p=dealii.git Add a script that validates whether cross-references in out documentation are valid or stale. It does not check external references, but it can check references within our directory tree. git-svn-id: https://svn.dealii.org/trunk@2413 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/doc/Makefile b/deal.II/doc/Makefile index 9cb5d5f0b6..fb646561ba 100644 --- a/deal.II/doc/Makefile +++ b/deal.II/doc/Makefile @@ -2,7 +2,7 @@ # generic targets -default: autogen-doc tutorial development +default: autogen-doc tutorial development validate-xrefs all: default autogen-doc-all @@ -22,9 +22,15 @@ tutorial: development: cd development ; $(MAKE) + +validate-xrefs: + @echo "Validating cross-references in HTML files." + cd tutorial ; $(MAKE) validate-xrefs + cd development ; $(MAKE) validate-xrefs + clean: cd auto ; $(MAKE) clean cd tutorial ; $(MAKE) clean cd development ; $(MAKE) clean -.PHONY: default all autogen-doc autogen-doc-all tutorial clean development +.PHONY: default all autogen-doc autogen-doc-all tutorial clean development validate-xrefs diff --git a/deal.II/doc/aural.css b/deal.II/doc/aural.css deleted file mode 100644 index 5fc0eca2df..0000000000 --- a/deal.II/doc/aural.css +++ /dev/null @@ -1,21 +0,0 @@ -body {} - -frameset {} - -td {} - -dt {} - -.figure {} - -.pagetoc {} - -.chapter_title {} - - -span.parhead {} - -span.example {} -pre.example {} -table.navbar {} - diff --git a/deal.II/doc/auto/scripts/validate-xrefs.pl b/deal.II/doc/auto/scripts/validate-xrefs.pl new file mode 100644 index 0000000000..78b3a1e598 --- /dev/null +++ b/deal.II/doc/auto/scripts/validate-xrefs.pl @@ -0,0 +1,84 @@ +# $Id$ +# Check whether references in HTML files are valid or +# point to non-existing files/links/etc +# +# Author: Wolfgang Bangerth, 2000 + + +# set this to 1 if you want verbose output +$debug = 0; + +foreach $filename (@ARGV) { + open IN, $filename + or die "---Can't open file `$filename'\n"; + + print "File: $filename\n" if $debug; + while () { + # first find all hrefs + while ( /href=\"?(.*?)[\s\"]/g ) { + # then decide whether they are relevant for + # our purpose + $link = $1; + + if ( $link =~ /^mailto|http/ ) { + # link is external. don't check it + print "external link: $link\n" if $debug; + next; + } + elsif ( $link =~ /^#(.*)/ ) + { + # this is a reference within this file. try to + # find its anchor + $internal_ref = $1; + print "internal reference: $link\n" if $debug; + + open IN2, $filename; + $found = 0; + while ( ) { + if ( / ) { + if ( / $@ +validate-xrefs: + $(PERL) $D/doc/auto/scripts/validate-xrefs.pl \ + $(filter-out makefiles.1.html makefiles.2.html, \ + $(shell echo *.html)) + + + clean: -rm -f makefiles.html makefile.small.html makefile.large.html -.PHONY: default clean +.PHONY: default validate-xrefs clean diff --git a/deal.II/doc/development/index.html b/deal.II/doc/development/index.html index 1f266280ed..1696f44988 100644 --- a/deal.II/doc/development/index.html +++ b/deal.II/doc/development/index.html @@ -5,7 +5,6 @@ deal.II Homepage - diff --git a/deal.II/doc/development/makefiles.1.html b/deal.II/doc/development/makefiles.1.html index da10719c54..eb7eb6fef0 100644 --- a/deal.II/doc/development/makefiles.1.html +++ b/deal.II/doc/development/makefiles.1.html @@ -4,7 +4,6 @@ - The deal.II Homepage - Makefiles diff --git a/deal.II/doc/development/navbar.html b/deal.II/doc/development/navbar.html index 21cabea191..594f88dd43 100644 --- a/deal.II/doc/development/navbar.html +++ b/deal.II/doc/development/navbar.html @@ -5,7 +5,6 @@ deal.II Homepage - diff --git a/deal.II/doc/development/recent-changes.html b/deal.II/doc/development/recent-changes.html index d8bd25c469..0e03458b70 100644 --- a/deal.II/doc/development/recent-changes.html +++ b/deal.II/doc/development/recent-changes.html @@ -4,7 +4,6 @@ - The deal.II Homepage @@ -127,7 +126,7 @@
  • - A backlog + A backlog of changes made to the CVS archive in the last 100 days.

    diff --git a/deal.II/doc/development/title.html b/deal.II/doc/development/title.html index 975b75b65a..23e9c65a96 100644 --- a/deal.II/doc/development/title.html +++ b/deal.II/doc/development/title.html @@ -9,7 +9,6 @@ deal.II Homepage - diff --git a/deal.II/doc/development/toc.html b/deal.II/doc/development/toc.html index bd5e8c38bd..bbcc448ff2 100644 --- a/deal.II/doc/development/toc.html +++ b/deal.II/doc/development/toc.html @@ -4,7 +4,6 @@ - The deal.II Homepage diff --git a/deal.II/doc/development/writing-documentation.html b/deal.II/doc/development/writing-documentation.html index 3cbc26a7cd..093d7a85a8 100644 --- a/deal.II/doc/development/writing-documentation.html +++ b/deal.II/doc/development/writing-documentation.html @@ -4,7 +4,6 @@ - The deal.II Homepage - Makefiles diff --git a/deal.II/doc/future.html b/deal.II/doc/future.html index dc177871d5..c85c86146d 100644 --- a/deal.II/doc/future.html +++ b/deal.II/doc/future.html @@ -4,7 +4,6 @@ - The deal.II Homepage diff --git a/deal.II/doc/index.html b/deal.II/doc/index.html index 9aab0307a8..a73ee6f28b 100644 --- a/deal.II/doc/index.html +++ b/deal.II/doc/index.html @@ -5,7 +5,6 @@ deal.II Homepage - diff --git a/deal.II/doc/license.html b/deal.II/doc/license.html index e332a08173..57ab10ac75 100644 --- a/deal.II/doc/license.html +++ b/deal.II/doc/license.html @@ -4,7 +4,6 @@ - The deal.II Readme @@ -49,7 +48,7 @@ thus appropriate for people wishing to write software under the model where all source code to the software is made available to all users and can be freely modified and redistributed.

    The QPL prohibits development of -proprietary software. For Qt our Qt Professional +proprietary software. For Qt our Qt Professional Edition product is available for this.

    diff --git a/deal.II/doc/navbar.html b/deal.II/doc/navbar.html index 008f5d0fc6..430a597351 100644 --- a/deal.II/doc/navbar.html +++ b/deal.II/doc/navbar.html @@ -5,7 +5,6 @@ deal.II Homepage - diff --git a/deal.II/doc/readme.html b/deal.II/doc/readme.html index d1ea632956..84c1f6e333 100644 --- a/deal.II/doc/readme.html +++ b/deal.II/doc/readme.html @@ -4,7 +4,6 @@ - The deal.II Readme diff --git a/deal.II/doc/title.html b/deal.II/doc/title.html index 99e530f556..3ea3b0ca7c 100644 --- a/deal.II/doc/title.html +++ b/deal.II/doc/title.html @@ -9,7 +9,6 @@ deal.II Homepage - diff --git a/deal.II/doc/toc.html b/deal.II/doc/toc.html index e2b25a1804..9974413dea 100644 --- a/deal.II/doc/toc.html +++ b/deal.II/doc/toc.html @@ -4,7 +4,6 @@ - The deal.II Homepage @@ -96,7 +95,7 @@ managing the library, contributing code, and writing documentation. Guido - Kanschat started contributing advice in the early + Kanschat helped with advice in the early implementation stages on questions of the design of object-oriented finite element software and later joined into the coding.