diff --git a/AUTHORS b/AUTHORS deleted file mode 100644 index d6c1a2a..0000000 --- a/AUTHORS +++ /dev/null @@ -1 +0,0 @@ -imacat diff --git a/AUTHORS.zh-cn b/AUTHORS.zh-cn deleted file mode 100644 index 2e02909..0000000 --- a/AUTHORS.zh-cn +++ /dev/null @@ -1 +0,0 @@ -依玛猫 diff --git a/AUTHORS.zh-tw b/AUTHORS.zh-tw deleted file mode 100644 index 2ec7e15..0000000 --- a/AUTHORS.zh-tw +++ /dev/null @@ -1 +0,0 @@ -ㄌ嚎窟 diff --git a/Build.PL b/Build.PL index 9d13513..1cefcbf 100755 --- a/Build.PL +++ b/Build.PL @@ -9,7 +9,7 @@ my $build = Module::Build->new( dist_version_from => "chklinks", dist_abstract => "A non-threaded Perl link checker", dist_author => "imacat ", - license => "gpl", + license => "apache_2_0", sign => 1, script_files => [ "chklinks" ], diff --git a/COPYING b/COPYING deleted file mode 100644 index 94a9ed0..0000000 --- a/COPYING +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. diff --git a/Changes b/Changes index 610e4cf..b14c377 100644 --- a/Changes +++ b/Changes @@ -1,7 +1,21 @@ chklinks change log +2020-02-06 + 1. Replaced the messy GNU-styled, multi-lingual documents with a + single Markdown README.md. + 2. Added the GitHub repository to the document, and removed the + SourceForge website, my web page, and the SourceForge mailing + list from the document. + 3. Removed the document license, and my PGP key from the package. + Removed the signature file from the repository. + 4. Changed the license from GPLv3 to APLv2. + 5. Various fixes to avoid JetBrains IDE problem detection. + +2020-02-01 + chklinks is hosted on GitHub now. + 2008-11-18 - 1. INSTALL: Fixed the grammer on installation with the CPAN or + 1. INSTALL: Fixed the grammar on installation with the CPAN or CPANPLUS shell, changed "install with the CPAN shell using" and "install with the CPANPLUS shell using" to "install it with the CPAN shell by running" and "install it with the @@ -23,10 +37,10 @@ chklinks change log 1. INSTALL: Updated information on required and optional Perl modules, to describe different installation commands for different operating systems. - 2. INSTALL: Fixed the grammer on the notes that required modules + 2. INSTALL: Fixed the grammar on the notes that required modules are automatically installed if install from the CPAN or CPANPLUS shell. - 2. chklinks.en.html: Fixed the grammer of the required modules, + 2. chklinks.en.html: Fixed the grammar of the required modules, changed "is part of the xxx package" to "is contained in the xxx distribution". @@ -43,8 +57,8 @@ chklinks change log 2007-12-05 version 3.08 Documentation fixes. 1. README.zh-*, chklinks.zh-*.html: Fixed the description - "琌ノ Perl 糶虫磅︽狐硈挡浪琩祘Α" to "琌虫磅︽狐 Perl 硈挡 - 浪琩祘Α", according to the existing short description in + "鏄敤 Perl 瀵殑鍠煼琛岀窉閫g祼妾㈡煡绋嬪紡" to "鏄柈鍩疯绶掔殑 Perl 閫g祼 + 妾㈡煡绋嬪紡", according to the existing short description in README.zh-tw. I was out of my mind to miss this and translate it again. 2. chklinks.zh-tw.html, chklinks.zh-cn.html: Removed the old @@ -248,7 +262,7 @@ chklinks change log 8. FDL added. 2003-05-25 version 2.01 - 1. An installer, accessary files and a POD document are added. + 1. An installer, accessory files and a POD document are added. 2003-05-25 version 2.0.0 1. First public release uploaded onto SourceForge. diff --git a/INSTALL b/INSTALL deleted file mode 100644 index becf680..0000000 --- a/INSTALL +++ /dev/null @@ -1,166 +0,0 @@ -chklinks Installation Guide - -* Table of Contents - - * System Requirements - * Installation Instruction - ** Install with ExtUtils::MakeMaker - ** Install with Module::Build - - -* System Requirements - - 1. Perl, version 5.6 or above. I have not successfully run this -on earlier versions. Please tell me if you can. You can run -"perl -v" to see your current Perl version. Perl is distributed -with most Unix now. If not, or if you have an older version of Perl, -you can download and install/upgrade it from Perl website. - -http://www.perl.com/ - - If you are using MS-Windows, you can download and install -ActiveState ActivePerl. - -http://www.activestate.com/ - - 2. Required Perl modules: - - * URI - - This is used to parse and process the found URLs. - You can download and install URI from the CPAN archive - http://search.cpan.org/dist/URI/ , - or install it with the CPAN shell by running "cpan URI", - or install it with the CPANPLUS shell by running - "cpanp i URI". - Debian/Ubandu Linux users can install it by running - "apt-get install liburi-perl". - Red Hat/Fedora/CentOS Linux users can install it by running - "yum install perl-URI". - FreeBSD users can install it by running - "ports install p5-URI". - ActivePerl users can install it by running - "ppm install URI". - - * HTML::LinkExtor - - This is used to extract links from the web pages. - HTML::LinkExtor is contained in the HTML-Parser distribution. - You can download and install HTML::LinkExtor from the CPAN archive - http://search.cpan.org/dist/HTML-Parser/ , - or install it with the CPAN shell by running "cpan HTML::LinkExtor", - or install it with the CPANPLUS shell by running - "cpanp i HTML::LinkExtor". - Debian/Ubandu Linux users can install it by running - "apt-get install libhtml-parser-perl". - Red Hat/Fedora/CentOS Linux users can install it by running - "yum install perl-HTML-Parser". - FreeBSD users can install it by running - "ports install p5-HTML-Parser". - ActivePerl users can install it by running - "ppm install HTML::LinkExtor". - - * LWP::RobotUA - - This is used to request web pages. - LWP::RobotUA is contained in the libwww-perl distribution. - You can download and install LWP::RobotUA from the CPAN archive - http://search.cpan.org/dist/libwww-perl/ , - or install it with the CPAN shell by running "cpan LWP::RobotUA", - or install it with the CPANPLUS shell by running - "cpanp i LWP::RobotUA". - Debian/Ubandu Linux users can install it by running - "apt-get install libwww-perl". - Red Hat/Fedora/CentOS Linux users can install it by running - "yum install perl-libwww-perl". - FreeBSD users can install it by running - "ports install p5-libwww". - ActivePerl users can install it by running - "ppm install LWP::RobotUA". - - If you install chklinks with the CPAN or CPANPLUS shell, the above - shall be automatically installed. - - 3. Optional Perl modules: - - * Crypt::SSLeay - - This is needed for LWP::RobotUA to support HTTPS. - You can download and install Crypt::SSLeay from the CPAN archive - http://search.cpan.org/dist/Crypt-SSLeay/ , - or install it with the CPAN shell by running "cpan Crypt::SSLeay", - or install it with the CPANPLUS shell by running - "cpanp i Crypt::SSLeay". - Debian/Ubandu Linux users can install it by running - "apt-get install libcrypt-ssleay-perl". - Red Hat/Fedora/CentOS Linux users can install it by running - "yum install perl-Crypt-SSLeay". - FreeBSD users can install it by running - "ports install p5-Crypt-SSLeay". - ActiveState does not host the PPM build of Crypt::SSLeay for - ActivePerl due to the Canadian Federal Government requirement. - However, ActivePerl users can still install it from another - repository, by running - "ppm install http://theoryx5.uwinnipeg.ca/ppms/Crypt-SSLeay.ppd" - - -* Installation Instruction - -** Install with ExtUtils::MakeMaker - - chklinks uses standard Perl installation with ExtUtils::MakeMaker. -Follow these steps: - - % perl Makefile.PL - % make - % make test - % make install - - When running make install, make sure you have the priviledge to -write to the installation location. This usually requires the root -priviledge. - - If you are using ActivePerl under MS-Windows, you should use -nmake instead of make. nmake can be obtained from the Microsoft FTP -site. - -ftp://ftp.microsoft.com/Softlib/MSLFILES/nmake15.exe - - If you want to install into another location, you can set the -PREFIX. For example, to install into your home when you are not -root: - - % perl Makefile.PL PREFIX=/home/jessica - - Refer to the docuemntation of ExtUtils::MakeMaker for more -installation options (by running perldoc ExtUtils::MakeMaker). - - -** Install with Module::Build - - You can install with Module::Build instead, if you prefer. -Follow these steps: - - % perl Build.PL - % ./Build - % ./Build test - % ./Build install - - When running ./Build install, make sure you have the priviledge to -write to the installation location. This usually requires the root -priviledge. - - If you want to install into another location, you can set the ---prefix. For example, to install into your home when you are not -root: - - % perl Build.PL --prefix=/home/jessica - - Refer to the docuemntation of Module::Build for more -installation options (by running perldoc Module::Build). - - -imacat -2008-11-17 -imacat@mail.imacat.idv.tw -http://www.imacat.idv.tw/ diff --git a/INSTALL.zh-cn b/INSTALL.zh-cn deleted file mode 100644 index fdbcaa1..0000000 --- a/INSTALL.zh-cn +++ /dev/null @@ -1,153 +0,0 @@ -chklinks 安装指南 - -◎目录 - - ◎系统需求 - ◎安装指南 - ◎◎以 ExtUtils::MakeMaker 安装 - ◎◎以 Module::Build 安装 - - -◎系统需求 - - 1. Perl 5.6 或以上。我还没有在更早的版本上成功执行过。若你可以在更 -早的版本上执行,请告诉我。你可以输入 perl -v 查询你目前的 Perl 版本。 -目前大多数的 Unix 系统都有 Perl 。如果你没有 Perl 或需要升级,可以到 -Perl 网站下载安装最新版 Perl 。 - - http://www.perl.com/ - - 若你是用 MS-Windows ,可以下载安装 ActiveState 公司的 ActivePerl 。 - - http://www.activestate.com/ - - 2. 需搭配的 Perl 模组: - - * URI - - 这是解析、处理网址用的。 - 你可以由 CPAN 模组库下载安装 URI : - http://search.cpan.org/dist/URI/ , - 或用 CPAN Shell 执行 cpan URI 安装, - 或用 CPANPLUS Shell 执行 cpanp i URI 安装。 - 若你是 Debian/Ubandu Linux 使用者,可以执行 - apt-get install liburi-perl 安装。 - 若你是 Red Hat/Fedora/CentOS Linux 使用者,可以执行 - yum install perl-URI 安装。 - 若你是 FreeBSD 使用者,可以执行 - ports install p5-URI 安装。 - 若你是 ActivePerl 使用者,可以执行 - ppm install URI 安装。 - - * HTML::LinkExtor - - 这是由网页里找出连结用的。 - HTML::LinkExtor 为 HTML-Parser 中的模组。 - 你可以由 CPAN 模组库下载安装 HTML::LinkExtor : - http://search.cpan.org/dist/HTML-Parser/ , - 或用 CPAN Shell 执行 cpan HTML::LinkExtor 安装, - 或用 CPANPLUS Shell 执行 cpanp i HTML::LinkExtor 安装。 - 若你是 Debian/Ubandu Linux 使用者,可以执行 - apt-get install libhtml-parser-perl 安装。 - 若你是 Red Hat/Fedora/CentOS Linux 使用者,可以执行 - yum install perl-HTML-Parser 安装。 - 若你是 FreeBSD 使用者,可以执行 - ports install p5-HTML-Parser 安装。 - 若你是 ActivePerl 使用者,可以执行 - ppm install HTML::LinkExtor 安装。 - - * LWP::RobotUA - - 这是抓取网页用的。 - LWP::RobotUA 为 libwww-perl 中的模组。 - 你可以由 CPAN 模组库下载安装 LWP::RobotUA : - http://search.cpan.org/dist/libwww-perl/ , - 或用 CPAN Shell 执行 cpan LWP::RobotUA 安装, - 或用 CPANPLUS Shell 执行 cpanp i LWP::RobotUA 安装。 - 若你是 Debian/Ubandu Linux 使用者,可以执行 - apt-get install libwww-perl 安装。 - 若你是 Red Hat/Fedora/CentOS Linux 使用者,可以执行 - yum install perl-libwww-perl 安装。 - 若你是 FreeBSD 使用者,可以执行 - ports install p5-libwww 安装。 - 若你是 ActivePerl 使用者,可以执行 - ppm install LWP::RobotUA 安装。 - - 若你由 CPAN 或 CPANPLUS Shell 安装 chklinks ,会自动帮你安装以 - 上所需的模组。 - - 3. 选配的 Perl 模组: - - * Crypt::SSLeay - - 这是读取设定档用的。 - 你可以由 CPAN 模组库下载安装 Crypt::SSLeay : - http://search.cpan.org/dist/Crypt-SSLeay/ , - 或用 CPAN Shell 执行 cpan Crypt::SSLeay 安装, - 或用 CPANPLUS Shell 执行 cpanp i Crypt::SSLeay 安装。 - 若你是 Debian/Ubandu Linux 使用者,可以执行 - apt-get install libcrypt-ssleay-perl 安装。 - 若你是 Red Hat/Fedora/CentOS Linux 使用者,可以执行 - yum install perl-Crypt-SSLeay 安装。 - 若你是 FreeBSD 使用者,可以执行 - ports install p5-Crypt-SSLeay 安装。 - 因加拿大联邦政府的规定, ActiveState 公司无法提供 Crypt::SSLeay - 的 ActivePerl PPM 套件安装。不过若你是 ActivePerl 使用者,还是 - 可以改由其它套件库,执行 - ppm install http://theoryx5.uwinnipeg.ca/ppms/Crypt-SSLeay.ppd - 安装。 - - -◎安装指南 - -◎◎以 ExtUtils::MakeMaker 安装 - - chklinks 用 Perl 标准的 ExtUtils::MakeMaker 安装,程序如下: - - % perl Makefile.PL - % make - % make test - % make install - - 在 make install 前,请先确认你有在安装目录存档的权限。通常这时候 -要切换为 root ,才能安装存档。 - - 若你是用 MS-Windows 下的 ActivePerl , make 请改用 nmake 。 nmake -可由微软的 FTP 站下载: - - ftp://ftp.microsoft.com/Softlib/MSLFILES/nmake15.exe - - 若要安装到其它地方,请设定好 PREFIX 。例如,一般使用者,要安装在 -自己的目录下时: - - % perl Makefile.PL PREFIX=/home/jessica - - 要知道更多安装选项的细节,请参阅 ExtUtils::MakeMaker 的说明(请执 -行 perldoc ExtUtils::MakeMaker )。 - - -◎◎以 Module::Build 安装 - - 若你喜欢,也可以用 Module::Build 安装,程序如下: - - % perl Build.PL - % ./Build - % ./Build test - % ./Build install - - 在 ./Build install 前,请先确认你有在安装目录存档的权限。通常这时 -候要切换为 root ,才能安装存档。 - - 若要安装到其它地方,请设定好 --prefix 。例如,一般使用者,要安装 -在自己的目录下时: - - % perl Build.PL --prefix=/home/jessica - - 要知道更多安装选项的细节,请参阅 Module::Build 的说明(请执行 -perldoc Module::Build )。 - - -依玛猫 imacat ^_*' -2008-11-18 -imacat@mail.imacat.idv.tw -http://www.imacat.idv.tw/ diff --git a/INSTALL.zh-tw b/INSTALL.zh-tw deleted file mode 100644 index 870a8e2..0000000 --- a/INSTALL.zh-tw +++ /dev/null @@ -1,153 +0,0 @@ -chklinks 杆玭 - -》ヘ魁 - - 》╰参惠― - 》杆玭 - 》》 ExtUtils::MakeMaker 杆 - 》》 Module::Build 杆 - - -》╰参惠― - - 1. Perl 5.6 ┪и临⊿ΤΝセΘ磅︽筁璝﹑ -Νセ磅︽叫禗и﹑块 perl -v 琩高﹑ヘ玡 Perl セ -ヘ玡计 Unix ╰参常Τ Perl 狦﹑⊿Τ Perl ┪惠璶狜 -Perl 呼更杆程穝 Perl  - - http://www.perl.com/ - - 璝﹑琌ノ MS-Windows 更杆 ActiveState そ ActivePerl  - - http://www.activestate.com/ - - 2. 惠穎皌 Perl 家舱 - - * URI - - 硂琌秆猂矪瞶呼ノ - ﹑パ CPAN 家舱畐更杆 URI  - http://search.cpan.org/dist/URI/  - ┪ノ CPAN Shell 磅︽ cpan URI 杆 - ┪ノ CPANPLUS Shell 磅︽ cpanp i URI 杆 - 璝﹑琌 Debian/Ubandu Linux ㄏノ磅︽ - apt-get install liburi-perl 杆 - 璝﹑琌 Red Hat/Fedora/CentOS Linux ㄏノ磅︽ - yum install perl-URI 杆 - 璝﹑琌 FreeBSD ㄏノ磅︽ - ports install p5-URI 杆 - 璝﹑琌 ActivePerl ㄏノ磅︽ - ppm install URI 杆 - - * HTML::LinkExtor - - 硂琌パ呼т硈挡ノ - HTML::LinkExtor  HTML-Parser い家舱 - ﹑パ CPAN 家舱畐更杆 HTML::LinkExtor  - http://search.cpan.org/dist/HTML-Parser/  - ┪ノ CPAN Shell 磅︽ cpan HTML::LinkExtor 杆 - ┪ノ CPANPLUS Shell 磅︽ cpanp i HTML::LinkExtor 杆 - 璝﹑琌 Debian/Ubandu Linux ㄏノ磅︽ - apt-get install libhtml-parser-perl 杆 - 璝﹑琌 Red Hat/Fedora/CentOS Linux ㄏノ磅︽ - yum install perl-HTML-Parser 杆 - 璝﹑琌 FreeBSD ㄏノ磅︽ - ports install p5-HTML-Parser 杆 - 璝﹑琌 ActivePerl ㄏノ磅︽ - ppm install HTML::LinkExtor 杆 - - * LWP::RobotUA - - 硂琌ъ呼ノ - LWP::RobotUA  libwww-perl い家舱 - ﹑パ CPAN 家舱畐更杆 LWP::RobotUA  - http://search.cpan.org/dist/libwww-perl/  - ┪ノ CPAN Shell 磅︽ cpan LWP::RobotUA 杆 - ┪ノ CPANPLUS Shell 磅︽ cpanp i LWP::RobotUA 杆 - 璝﹑琌 Debian/Ubandu Linux ㄏノ磅︽ - apt-get install libwww-perl 杆 - 璝﹑琌 Red Hat/Fedora/CentOS Linux ㄏノ磅︽ - yum install perl-libwww-perl 杆 - 璝﹑琌 FreeBSD ㄏノ磅︽ - ports install p5-libwww 杆 - 璝﹑琌 ActivePerl ㄏノ磅︽ - ppm install LWP::RobotUA 杆 - - 璝﹑パ CPAN ┪ CPANPLUS Shell 杆 chklinks 穦笆腊﹑杆 - ┮惠家舱 - - 3. 匡皌 Perl 家舱 - - * Crypt::SSLeay - - 硂琌弄砞﹚郎ノ - ﹑パ CPAN 家舱畐更杆 Crypt::SSLeay  - http://search.cpan.org/dist/Crypt-SSLeay/  - ┪ノ CPAN Shell 磅︽ cpan Crypt::SSLeay 杆 - ┪ノ CPANPLUS Shell 磅︽ cpanp i Crypt::SSLeay 杆 - 璝﹑琌 Debian/Ubandu Linux ㄏノ磅︽ - apt-get install libcrypt-ssleay-perl 杆 - 璝﹑琌 Red Hat/Fedora/CentOS Linux ㄏノ磅︽ - yum install perl-Crypt-SSLeay 杆 - 璝﹑琌 FreeBSD ㄏノ磅︽ - ports install p5-Crypt-SSLeay 杆 - 羛ü現┎砏﹚ ActiveState そ礚猭矗ㄑ Crypt::SSLeay -  ActivePerl PPM 甅ン杆ぃ筁璝﹑琌 ActivePerl ㄏノ临琌 - эパㄤウ甅ン畐磅︽ - ppm install http://theoryx5.uwinnipeg.ca/ppms/Crypt-SSLeay.ppd - 杆 - - -》杆玭 - -》》 ExtUtils::MakeMaker 杆 - - chklinks ノ Perl 夹非 ExtUtils::MakeMaker 杆祘 - - % perl Makefile.PL - % make - % make test - % make install - -  make install 玡叫絋粄﹑Τ杆ヘ魁郎舦硄盽硂 -璶ち传 root 杆郎 - - 璝﹑琌ノ MS-Windows  ActivePerl  make 叫эノ nmake  nmake -パ稬硁 FTP 更 - - ftp://ftp.microsoft.com/Softlib/MSLFILES/nmake15.exe - - 璝璶杆ㄤウよ叫砞﹚ PREFIX ㄒㄏノ璶杆 -ヘ魁 - - % perl Makefile.PL PREFIX=/home/jessica - - 璶笵杆匡兜灿竊叫把綷 ExtUtils::MakeMaker 弧叫磅 -︽ perldoc ExtUtils::MakeMaker  - - -》》 Module::Build 杆 - - 璝﹑尺舧ノ Module::Build 杆祘 - - % perl Build.PL - % ./Build - % ./Build test - % ./Build install - -  ./Build install 玡叫絋粄﹑Τ杆ヘ魁郎舦硄盽硂 -璶ち传 root 杆郎 - - 璝璶杆ㄤウよ叫砞﹚ --prefix ㄒㄏノ璶杆 -ヘ魁 - - % perl Build.PL --prefix=/home/jessica - - 璶笵杆匡兜灿竊叫把綷 Module::Build 弧叫磅︽ -perldoc Module::Build  - - -ㄌ嚎窟 imacat ^_*' -2008-11-18 -imacat@mail.imacat.idv.tw -http://www.imacat.idv.tw/ diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..d645695 --- /dev/null +++ b/LICENSE @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/MANIFEST b/MANIFEST deleted file mode 100644 index ef4408a..0000000 --- a/MANIFEST +++ /dev/null @@ -1,36 +0,0 @@ -AUTHORS -AUTHORS.zh-cn -AUTHORS.zh-tw -Build.PL -Changes -chklinks -chklinks.en.html -chklinks.zh-cn.html -chklinks.zh-tw.html -COPYING -fdl.txt -INSTALL -INSTALL.zh-cn -INSTALL.zh-tw -Makefile.PL -MANIFEST This list of files -META.yml -NEWS -pgpkey.asc -README -README.zh-cn -README.zh-tw -SIGNATURE -t/00-signature.t -t/01-basic.t -t/99-pod.t -t/htdocs/dir01/start.html -t/htdocs/dir01/test01.html -t/htdocs/stylesheets/test.css -t/htdocs/test03.html -THANKS -THANKS.zh-cn -THANKS.zh-tw -TODO -TODO.zh-cn -TODO.zh-tw diff --git a/MANIFEST.SKIP b/MANIFEST.SKIP new file mode 100644 index 0000000..4b50038 --- /dev/null +++ b/MANIFEST.SKIP @@ -0,0 +1,14 @@ +^blib/ +^Makefile$ +^Build$ +^_build/ +^MANIFEST\.bak$ +^MYMETA\.yml$ +^MYMETA\.json$ +^SIGNATURE$ +^pm_to_blib$ +^\.git/ +^\.gitignore$ +^\.idea/ +^excludes/ +^t/logs.*/ diff --git a/META.yml b/META.yml deleted file mode 100644 index 2a46000..0000000 --- a/META.yml +++ /dev/null @@ -1,18 +0,0 @@ ---- #YAML:1.0 -name: chklinks -version: 3.09 -abstract: A non-threaded Perl link checker -license: gpl -author: - - imacat -generated_by: ExtUtils::MakeMaker version 6.38 -distribution_type: module -requires: - HTML::LinkExtor: 0 - HTTP::Cookies: 0 - HTTP::Request: 0 - LWP::RobotUA: 0 - URI: 0 -meta-spec: - url: http://module-build.sourceforge.net/META-spec-v1.3.html - version: 1.3 diff --git a/Makefile.PL b/Makefile.PL index a358ff9..88945db 100755 --- a/Makefile.PL +++ b/Makefile.PL @@ -6,7 +6,7 @@ use warnings; use ExtUtils::MakeMaker; # Optional prerequisite modules -use vars qw(%OPT_PREREQ); +our (%OPT_PREREQ); %OPT_PREREQ = ( "Crypt::SSLeay" => 0, ); @@ -26,7 +26,7 @@ WriteMakefile( VERSION_FROM => "chklinks", ABSTRACT => "A non-threaded Perl link checker", AUTHOR => "imacat ", - LICENSE => "gpl", + LICENSE => "apache_2_0", PREREQ_PM => { "URI" => 0, "LWP::RobotUA" => 0, diff --git a/NEWS b/NEWS deleted file mode 100644 index 837230f..0000000 --- a/NEWS +++ /dev/null @@ -1,56 +0,0 @@ -New in 3.09: -* Fixed the bug on systems like MS-Windows that does not have - getpwuid(). - -New in 3.08: -* Documentation fixes. - -New in 3.07: -* Required Perl version number compatible to older versions, to work - with the Perl 5.10 warning. -* License updated to GPLv3. -* Documentation fixes. - -New in 3.06: -* Test suite fixes. - -New in 3.05: -* Fixed the problem with Perl version earlier than 5.8 where - UTF-8 mode is not available. - -New in 3.04: -* Documentation fixes. - -New in 3.03: -* Fixed the raw UTF-8 warning with HTML::Parser >= 3.40. -* Added Build.PL to support Module::Build. - -New in 3.02: -* Digital signature corrected. -* Fixes in HTML document. - -New in 3.01: -* Bug fixes. -* HTML documents are returned. - -New in 3.00: -* chklinks follows robots.txt rules now. If you disallow robots from your - website and experience problems, you need to allow chklinks. Add the - following lines to your robots.txt file to allow chklinks: - - User-agent: chklinks - Disallow: - -* chklinks now uses LWP::RobotUA and support the following schemes in - addition to http: http, https, ftp, gopher, file. You can also specify a - local file. (To use https, you need to install Crypt::SSLeay.) -* Cookies are supported now. - -New in 2.02: -* The default changed from one-level to recursive. This is more - desirable in most cases. - -New in 2.01: -* An installer, accessary files and a POD document are added. - -New in 2.0.0: diff --git a/README b/README deleted file mode 100644 index 8abeec4..0000000 --- a/README +++ /dev/null @@ -1,69 +0,0 @@ -chklinks - A non-threaded Perl link checker. - - Copyright (c) 2003-2007 imacat. - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - - chklinks is a non-threaded Perl link checker. It helps finding -broken links on your website. - - chklinks differs from linkchecker in that chklinks is -non-threaded. It does not raises many simultaneously connections for -its job. It won't run out of the resources and crash your system in a -moment. This is certainly more desirable for most webmasters and -users. - - chklinks follows robots.txt rules. If you disallow robots from -your website and experience problems, you need to allow chklinks. -Add the following lines to your robots.txt file to allow chklinks: - - User-agent: chklinks - Disallow: - - chklinks uses LWP::RobotUA and support the following schemes: -http, https, ftp, gopher, file. You can also specify a local file. -(To use https, you need to install Crypt::SSLeay.) - - chklinks supports cookies. - - See INSTALL for instructions on how to install chklinks. - - If you encounter warnings like this: - - Parsing of undecoded UTF-8 will give garbage when decoding - entities at /usr/share/perl5/LWP/Protocol.pm line 114. - - This is an issue of LWP::Protocol version <= 1.43 (in libwww-perl -version <= 5.805) when working with HTML::Parser version >= 3.40 and -Perl version >= 5.8. This issue is solved in LWP::Protocol version ->= 1.46 (in libwww-perl version >= 5.806). You can upgrade your -LWP::Protocol to the current version. If you cannot upgrade it, see -CPAN RT Bug#20274 http://rt.cpan.org/Public/Bug/Display.html?id=20274 -for an LWP::Protocol patch on this. - - chklinks is hosted on SourceForge, CPAN and Tavern IMACAT's. For -the latest infomation, see: - - * http://chklinks.sourceforge.net/ - * http://sourceforge.net/projects/chklinks/ - * http://search.cpan.org/dist/chklinks/ - * http://www.imacat.idv.tw/tech/chklinks.html - - Report bugs to imacat . - - -imacat -2007-12-05 -imacat@mail.imacat.idv.tw -http://www.imacat.idv.tw/ diff --git a/README.md b/README.md new file mode 100644 index 0000000..8e331de --- /dev/null +++ b/README.md @@ -0,0 +1,413 @@ +`chklinks` - A Non-Threaded Perl Link Checker +============================================= + + +Description +----------- + +`chklinks` is a non-threaded Perl link checker. It helps to find +broken links on your website. + +`chklinks` differs from [linkchecker] in that `chklinks` is +non-threaded. It does not raise many simultaneously connections for +its job. It won鈥檛 run out of the resources and crash your system in a +moment. This is certainly more desirable for most webmasters and +users. + +`chklinks` respects `robots.txt`. If you disallow robots from your +website and experience problems, you need to allow `chklinks`. Add +the following lines to your `robots.txt` file to allow `chklinks`: + + User-agent: chklinks + Disallow: + +`chklinks` uses [LWP::RobotUA] and supports the following schemes: +`http`, `https`, `ftp`, `gopher` and `file`. You can also specify a +local file. (To use `https`, you need to install [Crypt::SSLeay]. +This is the requirement of LWP::RobotUA.) + +`chklinks` supports cookies. + +[linkchecker]: https://wummel.github.io/linkchecker +[LWP::RobotUA]: https://metacpan.org/pod/LWP::RobotUA +[Crypt::SSLeay]: https://metacpan.org/release/Crypt-SSLeay + + +System Requirement +------------------ + +1. Perl, version 5.6 or above. I have not successfully run this on + earlier versions. Please tell me if you can. You can run + `perl -v` to see your current Perl version. If you do not have + Perl, or if you have an older version of Perl, you can download and + install/upgrade it from the [Perl website]. If you are using + MS-Windows, you can download and install [ActiveState ActivePerl]. + +2. Required Perl modules: + + * [URI] + + This is used to parse and process the found URLs. You can + download and install URI from the CPAN archive, or install it + with the CPAN shell: + + cpan URI + + or with the CPANPLUS shell: + + cpanp i URI + + For Debian/Ubuntu: + + sudo apt install liburi-perl + + For Red Hat/Fedora/CentOS: + + sudo yum install perl-URI + + For FreeBSD: + + ports install p5-URI + + For ActivePerl: + + ppm install URI + + * [HTML::LinkExtor] + + This is used to extract links from the web pages. + HTML::LinkExtor is contained in the [HTML-Parser] distribution. + You can download and install HTML::LinkExtor from the CPAN + archive, or install it with the CPAN shell: + + cpan HTML::LinkExtor + + or with the CPANPLUS shell: + + cpanp i HTML::LinkExtor + + For Debian/Ubuntu: + + sudo apt install libhtml-parser-perl + + For Red Hat/Fedora/CentOS: + + sudo yum install perl-HTML-Parser + + For FreeBSD: + + ports install p5-HTML-Parser + + For ActivePerl: + + ppm install HTML-Parser + + * [LWP::RobotUA] + + This is used to request web pages. LWP::RobotUA is contained in + the [libwww-perl] distribution. You can download and install + LWP::RobotUA from the CPAN archive, or install it with the CPAN + shell: + + cpan LWP::RobotUA + + or with the CPANPLUS shell: + + cpanp i HTML::LinkExtor + + For Debian/Ubuntu: + + sudo apt install libwww-perl + + For Red Hat/Fedora/CentOS: + + sudo yum install perl-libwww-perl + + For FreeBSD: + + ports install p5-libwww + + For ActivePerl: + + ppm install libwww-perl + +3. Optional Perl modules: + + * [Crypt::SSLeay] + + This is needed by LWP::RobotUA to support HTTPS. You can + download and install HTML::LinkExtor from the CPAN archive, or + install it with the CPAN shell: + + cpan Crypt::SSLeay + + or with the CPANPLUS shell: + + cpanp i Crypt::SSLeay + + For Debian/Ubuntu: + + sudo apt install libcrypt-ssleay-perl + + For Red Hat/Fedora/CentOS: + + sudo yum install perl-Crypt-SSLeay + + For FreeBSD: + + ports install p5-Crypt-SSLeay + + For ActivePerl: + + ppm install Crypt-SSLeay + +[Perl website]: https://www.perl.org +[ActiveState ActivePerl]: https://www.activestate.com +[URI]: https://metacpan.org/release/URI +[HTML::LinkExtor]: https://metacpan.org/pod/HTML::LinkExtor +[HTML-Parser]: https://metacpan.org/release/HTML-Parser +[LWP::RobotUA]: https://metacpan.org/pod/LWP::RobotUA +[libwww-perl]: https://metacpan.org/release/libwww-perl +[Crypt::SSLeay]: https://metacpan.org/release/Crypt-SSLeay + + +Download +-------- + +`chklinks` is hosted is on鈥 + +* [chklinks project on GitHub] + +* [chklinks project on SourceForge] + +You can always download the newest version of `chklinks` from鈥 + +* [chklinks download on SourceForge] + +* [Tavern IMACAT鈥檚 FTP directory] + +imacat鈥檚 PGP public key is at鈥 + +* [imacat鈥檚 PGP key at Tavern IMACAT鈥檚] + +[chklinks project on GitHub]: https://github.com/imacat/chklinks +[chklinks project on SourceForge]: https://sf.net/p/chklinks +[chklinks download on SourceForge]: https://sourceforge.net/projects/chklinks/files +[Tavern IMACAT鈥檚 FTP directory]: https://ftp.imacat.idv.tw/pub/chklinks/ +[imacat鈥檚 PGP key at Tavern IMACAT鈥檚]: https://www.imacat.idv.tw/me/pgpkey.asc + + +Install +------- + +`chklinks` uses standard Perl installation with ExtUtils::MakeMaker. +Follow these steps: + + % perl Makefile.PL + % make + % make test + % make install + +When running `make install`, make sure you have the privilege to +write to the installation location. This usually requires the `root` +privilege. + +If you are using ActivePerl under MS-Windows, you should use `nmake` +instead of `make`. [nmake can be obtained from the Microsoft FTP site.] + +If you want to install into another location, you can set the +`PREFIX`. For example, to install into your home when you are not +`root`: + + % perl Makefile.PL PREFIX=/home/jessica + +Refer to the documentation of ExtUtils::MakeMaker for more +installation options (by running `perldoc ExtUtils::MakeMaker`). + +### Install with [Module::Build] + +You can install with Module::Build instead, if you prefer. Follow +these steps: + + % perl Build.PL + % ./Build + % ./Build test + % ./Build install + +When running `./Build install`, make sure you have the privilege to +write to the installation location. This usually requires the `root` +privilege. + +If you want to install into another location, you can set the +`--prefix`. For example, to install into your home when you are not +`root`: + + % perl Build.PL --prefix=/home/jessica + +Refer to the documentation of Module::Build for more installation +options (by running `perldoc Module::Build`). + +[ExtUtils::MakeMaker]: https://metacpan.org/release/ExtUtils-MakeMaker +[nmake can be obtained from the Microsoft FTP site.]: ftp://ftp.microsoft.com/Softlib/MSLFILES/nmake15.exe +[Module::Build]: https://metacpan.org/release/Module-Build + + +Options +------- + + ./chklinks [options] URL1 [URL2 [URL3 鈥] + ./chklinks [-h|-v] + +* `-1`, `--onelevel` + + Check the links on this page and stops. + +* `-r`, `--recursive` + + Recursively check through this website. This is the default. + +* `-b`, `--below` + + Only check the links below this directory. This is the default. + +* `-p`, `--parent` + + Trace back to the parent directories. + +* `-l`, `--local` + + Only check the links on this same host. + +* `-s`, `--span` + + Check the links to other hosts (without recursion). This is the + default. + +* `-e`, `--exclude path` + + Exclude this path. Check for their existence but not check the + links on them, just like they are on a foreign site. Multiple + `--exclude` are OK. + +* `-i`, `--include path` + + Include this path. An opposite of `--exclude` that cancels its + effect. The latter specified has a higher priority. + +* `-d`, `--debug` + + Display debug messages. Multiple `--debug` to debug more. + +* `-q`, `--quiet` + + Disable debug messages. An opposite that cancels the effect of + `--debug`. + +* `-h`, `--help` + + Display the help message and exit. + +* `-v`, `--version` + + Output version information and exit. + +* `URL1`, `URL2`, `URL3` + + The URLs of the websites to check against. + + +Notes +----- + +* `chklinks` does not obey `Crawl-delay:` in `robots.txt` yet. This + is a problem in [WWW::RobotRules], but not `chklinks` itself. + +* If you encounter warnings like this: + + Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/share/perl5/LWP/Protocol.pm line 114. + + This is an issue of [LWP::Protocol] version 鈮 1.43 (in libwww-perl + version 鈮 5.805) when working with HTML::Parser version 鈮 3.40 and + Perl version 鈮 5.8. This issue is solved in LWP::Protocol + version 鈮 1.46 (in libwww-perl version 鈮 5.806). You can upgrade + your LWP::Protocol to the current version. If you cannot upgrade + it, see [CPAN RT Bug#20274] for an LWP::Protocol patch on this. + +[WWW::RobotRules]: https://metacpan.org/pod/WWW::RobotRules +[LWP::Protocol]: https://metacpan.org/pod/LWP::Protocol +[CPAN RT Bug#20274]: https://rt.cpan.org/Public/Bug/Display.html?id=20274 + + +Bugs +---- + +`chklinks` does not support authentication yet. [W3C-LinkChecker] +supports this. As a workaround, You can use the syntax +`http://user:pass@some.where.com/some/path` for Basic Authentication, +but this does not work on Digest Authentication. This practice is +not encouraged. Your password would be visible to anyone on this +system using `ps`, including hidden intruders. Also, what you type +in your shell will be saved to your shell history file. + +`mailto:` URLs should be supported by checking the validity of its +DNS/MX record. Bastian Kleineidam's [linkchecker] have support on +this. + +Local file checking has only been tested on Unix and MSWin32. More +platforms should be tested, especially VMS and Mac. + +[W3C-LinkChecker]: https://validator.w3.org/checklink +[linkchecker]: https://wummel.github.io/linkchecker + + +See Also +-------- + +[LWP::UserAgent], [LWP::RobotUA], [WWW::RobotRules], [URI], +[HTML::LinkExtor], Bastian Kleineidam鈥檚 [linkchecker] and +W3C-LinkChecker [checklink]. + +[LWP::UserAgent]: https://metacpan.org/pod/LWP::UserAgent +[LWP::RobotUA]: https://metacpan.org/pod/LWP::RobotUA +[WWW::RobotRules]: https://metacpan.org/pod/WWW::RobotRules +[URI]: https://metacpan.org/release/URI +[HTML::LinkExtor]: https://metacpan.org/pod/HTML::LinkExtor +[linkchecker]: https://wummel.github.io/linkchecker +[checklink]: https://validator.w3.org/checklink + + +Release Notes +------------- + +Please read the `NEWS` for the new functions and bug fixes. + + +Support +------- + +The `chklinks` project is hosted on GitHub. Address your issues on the +GitHub issue tracker https://github.com/imacat/chklinks/issues. + + +License +------- + + Copyright (C) 2003-2021 imacat. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + +imacat ^_*' +2003/5/25 + +https://www.imacat.idv.tw diff --git a/README.zh-cn b/README.zh-cn deleted file mode 100644 index 1ed3ca5..0000000 --- a/README.zh-cn +++ /dev/null @@ -1,64 +0,0 @@ -chklinks - 单执行绪的 Perl 连结检查程式。 - - 版权所有 (c) 2003-2007 依玛猫 - - 本程式是自由软体,您可以遵照自由软体基金会 (Free Software Foundation) - 出版的 GNU 通用公共许可证条款 (GNU General Public License) 第三版来修 - 改和重新发布这一程式,或者自由选择使用任何更新的版本。 - - 发布这一程式的目的是希望它有用,但没有任何担保。甚至没有适合特定目的 - 而隐含的担保。更详细的情况请参阅 GNU 通用公共许可证。 - - 您应该已经和程式一起收到一份 GNU 通用公共许可证的副本。如果还没有,参 - 阅。 - - chklinks 是单执行绪的 Perl 连结检查程式,用来检查网站上的超连结有 -没有疏漏。 - - chklinks 和 linkchecker 不同之处在於,chklinks 不是多执行绪的程式 -。 chklinks 检查时,不会同时启动一大堆连线同步检查,耗尽系统资源,导致 -当机。对大多数网管和使用者而言,这样做安全得多。 - - chklinks 遵守 robots.txt 设定的规则。若你的网站拒绝自动网页程式, -导致 chklinks 无法执行,请在你的 robots.txt ,加入下列两行,放行 -chklinks : - - User-agent: chklinks - Disallow: - - chklinks 使用 LWP::RobotUA 连线,支援下列通讯协定: http 、 https -、 ftp 、 gopher 及 file 。chklinks 也可以检查一般的档案。(若要使用 -https 通讯协定,需先安装 Crypt::SSLeay 。这是 LWP::RobotUA 的需求。) - - chklinks 支援网站的 Cookies 。 - -  请详阅 INSTALL.zh-tw 档案的安装指南。 - -  若出现以下警告: - - Parsing of undecoded UTF-8 will give garbage when decoding - entities at /usr/share/perl5/LWP/Protocol.pm line 114. - -  这是 LWP::Protocol 1.43 版或之前的版本( libwww-perl 5.805 版或之 -前的版本),碰上 HTML::Parser 3.40 版或之后的版本及 Perl 5.8 版或之后 -的版本时,产生的问题。 LWP::Protocol 1.46 版以后( libwww-perl 5.806 -版以后),已解决这个问题。请升级到最新版的 LWP::Protocol 。若你因故无 -法升级,请参阅 CPAN RT Bug#20274 报告 -http://rt.cpan.org/Public/Bug/Display.html?id=20274 ,取得 -LWP::Protocol 的修补程式。 - - chklinks 网站架在 SourceForge 、 CPAN 与 旅舍依玛。索取最新资讯, -请驾临: - - * http://chklinks.sourceforge.net/ - * http://sourceforge.net/projects/chklinks/ - * http://search.cpan.org/dist/chklinks/ - * http://www.imacat.idv.tw/tech/chklinks.html - - 错误问题请回报给依玛猫 。 - - -依玛猫 imacat ^_*' -2007-12-05 -imacat@mail.imacat.idv.tw -http://www.imacat.idv.tw/ diff --git a/README.zh-tw b/README.zh-tw deleted file mode 100644 index 8f71049..0000000 --- a/README.zh-tw +++ /dev/null @@ -1,64 +0,0 @@ -chklinks - 虫磅︽狐 Perl 硈挡浪琩祘Α - - 舦┮Τ (c) 2003-2007 ㄌ嚎窟 - - セ祘Α琌パ硁砰眤宽酚パ硁砰膀穦 (Free Software Foundation) -  GNU 硄ノそ砛靡兵蹿 (GNU General Public License) 材ㄓ - э㎝穝祇硂祘Α┪パ匡拒ㄏノヴ穝セ - - 祇硂祘Αヘ琌辨ウΤノ⊿Τヴ踞玂⊿Τ続疭﹚ヘ - τ留踞玂冈灿薄猵叫把綷 GNU 硄ノそ砛靡 - - 眤莱赣竒㎝祘Α癬Μ GNU 硄ノそ砛靡捌セ狦临⊿Τ把 - 綷 - - chklinks 琌虫磅︽狐 Perl 硈挡浪琩祘Αノㄓ浪琩呼禬硈挡Τ -⊿Τ波簗 - - chklinks ㎝ linkchecker ぃぇ矪chklinks ぃ琌磅︽狐祘Α - chklinks 浪琩ぃ穦币笆帮硈絬˙浪琩荷╰参戈方旧璓 -讽诀癸计呼恨㎝ㄏノτē硂妓暗眔 - - chklinks 宽 robots.txt 砞﹚砏玥璝﹑呼┶荡笆呼祘Α -旧璓 chklinks 礚猭磅︽叫﹑ robots.txt ㄢ︽︽ -chklinks  - - User-agent: chklinks - Disallow: - - chklinks ㄏノ LWP::RobotUA 硈絬や穿硄癟﹚ http  https - ftp  gopher の file chklinks 浪琩郎璝璶ㄏノ -https 硄癟﹚惠杆 Crypt::SSLeay 硂琌 LWP::RobotUA 惠― - - chklinks や穿呼 Cookies  - -叫冈綷 INSTALL.zh-tw 郎杆玭 - -璝瞷牡 - - Parsing of undecoded UTF-8 will give garbage when decoding - entities at /usr/share/perl5/LWP/Protocol.pm line 114. - -硂琌 LWP::Protocol 1.43 ┪ぇ玡セ libwww-perl 5.805 ┪ぇ -玡セ窱 HTML::Parser 3.40 ┪ぇセの Perl 5.8 ┪ぇ -セ玻ネ拜肈 LWP::Protocol 1.46  libwww-perl 5.806 -秆∕硂拜肈叫狜程穝 LWP::Protocol 璝﹑珿礚 -猭狜叫把綷 CPAN RT Bug#20274 厨 -http://rt.cpan.org/Public/Bug/Display.html?id=20274 眔 -LWP::Protocol 干祘Α - - chklinks 呼琜 SourceForge  CPAN 籔 ㄌ嚎程穝戈癟 -叫緍羬 - - * http://chklinks.sourceforge.net/ - * http://sourceforge.net/projects/chklinks/ - * http://search.cpan.org/dist/chklinks/ - * http://www.imacat.idv.tw/tech/chklinks.html - - 岿粇拜肈叫厨倒ㄌ嚎窟  - - -ㄌ嚎窟 imacat ^_*' -2007-12-05 -imacat@mail.imacat.idv.tw -http://www.imacat.idv.tw/ diff --git a/SIGNATURE b/SIGNATURE deleted file mode 100644 index 1efd592..0000000 --- a/SIGNATURE +++ /dev/null @@ -1,58 +0,0 @@ -This file contains message digests of all files listed in MANIFEST, -signed via the Module::Signature module, version 0.55. - -To verify the content in this distribution, first make sure you have -Module::Signature installed, then type: - - % cpansign -v - -It will check each file's integrity, as well as the signature's -validity. If "==> Signature verified OK! <==" is not displayed, -the distribution may already have been compromised, and you should -not run its Makefile.PL or Build.PL. - ------BEGIN PGP SIGNED MESSAGE----- -Hash: SHA1 - -SHA1 91ced1a733e7448edc19eab22482508d58d7b284 AUTHORS -SHA1 c4c98cc9e7ac5e119752587d0322280a7a71d205 AUTHORS.zh-cn -SHA1 eb60ee204fcf7244fc0774ac34d05a35a281e82b AUTHORS.zh-tw -SHA1 8f43b147c64db8e26b5d23d6bb24eb6657086cf7 Build.PL -SHA1 8624bcdae55baeef00cd11d5dfcfa60f68710a02 COPYING -SHA1 75aac7f77e344c5729399d323beea3013d43be2d Changes -SHA1 85511344983264b042b7c9908b583f9ffc2883b0 INSTALL -SHA1 6c76a11efb973c28843dd78cd733916d435486dc INSTALL.zh-cn -SHA1 3964e72811c189abdf0289115cbc6cbb5de02263 INSTALL.zh-tw -SHA1 60d324fbf0b35d11d8fd87987570cedbace38bd8 MANIFEST -SHA1 de90a1e81bfc43c237b52011ea2537a2436971fa META.yml -SHA1 6f0121c588264962273ca3b011f02e1c5ca4c9e3 Makefile.PL -SHA1 9a30816755a9c25da556ef89435544c3428849a4 NEWS -SHA1 d4ba36b2a1ecf22309d47666945c26b0f8f87e14 README -SHA1 ffdefa6237871eccdf1a1be0f52981b20db038b0 README.zh-cn -SHA1 f507818867704af42bdfb80d5d9752a186522015 README.zh-tw -SHA1 fe6cf3c3671ab077d29c6aeb64b9db9b26d107bb THANKS -SHA1 8e4323b6f056b6e3a93e7b3b0b30eb4bd249cd67 THANKS.zh-cn -SHA1 424427d2171109c68c241fc58784469ba7f0fa6b THANKS.zh-tw -SHA1 0cbe7f0abc164955d82d31e84a93d032ced8fd87 TODO -SHA1 96fd7c6f911a55c0a2592986c23a3c4e7c01afad TODO.zh-cn -SHA1 44fbd7b0e7dd71d7b5db32cdb04a32b1659eb02e TODO.zh-tw -SHA1 d91e0060e0bcc305fb4823ccc229f91e8c550a81 chklinks -SHA1 bd986dcd9826fa048b1f159908e282a893ae7585 chklinks.en.html -SHA1 25bf7528bfb773674a0fbb346e51e53b91231d21 chklinks.zh-cn.html -SHA1 ff354f25166b0783a3d23729ee1b379823b124e5 chklinks.zh-tw.html -SHA1 bd75d59f9d7d9731bfabdc48ecd19e704d218e38 fdl.txt -SHA1 520fdcf4374af210380db9e0fdaea44c904a15fc pgpkey.asc -SHA1 525f414c7a0aadc61240a4b0959ca2cda7514c75 t/00-signature.t -SHA1 c58eed31af883caea4c3f4d9f963c5057ffe47be t/01-basic.t -SHA1 b85626024d610808bd0909989dcfb9fb20a40485 t/99-pod.t -SHA1 44d1b4b0f06828f3408981ee63f6462ba0fdf1c9 t/htdocs/dir01/start.html -SHA1 daff57a412711803ed645c8f868dfec64b2e66d0 t/htdocs/dir01/test01.html -SHA1 55800ebcc4a0ac8583e763499f98660fff117f33 t/htdocs/stylesheets/test.css -SHA1 e1fc75f156071ee26e5892db26af16ddfaec3316 t/htdocs/test03.html ------BEGIN PGP SIGNATURE----- -Version: GnuPG v1.4.7 (GNU/Linux) - -iD8DBQFHVvLHi9gubzC5S1wRAo/eAJwKjrbrXSfx9KSbIivDK3rj2qauqwCeIWBl -uZXV8T7lGCfm3z4oKu8jBHo= -=F4t/ ------END PGP SIGNATURE----- diff --git a/THANKS.zh-cn b/THANKS.zh-cn deleted file mode 100644 index 5491e0a..0000000 --- a/THANKS.zh-cn +++ /dev/null @@ -1,11 +0,0 @@ -  感谢 SourceForge 提供架设 reslog 专案。 - -  感谢 CPAN 提供架设 reslog 专案。 - -  感谢 SourceForge 提供 compile farm 各种平台供专案测试。 - -  感谢 Stefan Seifert 回报不支援 Cookies -时网页无限自我转向的问题。 (2005-11-07) - -  感谢 nsnake 回报检查 UTF-8 页面时, -HTML::Parser 3.40 版以上会出现警告讯息的问题。 (2007-06-06) diff --git a/THANKS.zh-tw b/THANKS.zh-tw deleted file mode 100644 index cf51d20..0000000 --- a/THANKS.zh-tw +++ /dev/null @@ -1,11 +0,0 @@ -稰谅 SourceForge 矗ㄑ琜砞 reslog 盡 - -稰谅 CPAN 矗ㄑ琜砞 reslog 盡 - -稰谅 SourceForge 矗ㄑ compile farm 贺キㄑ盡代刚 - -稰谅 Stefan Seifert 厨ぃや穿 Cookies -呼礚и锣拜肈 (2005-11-07) - -稰谅 nsnake 厨浪琩 UTF-8  -HTML::Parser 3.40 穦瞷牡癟拜肈 (2007-06-06) diff --git a/TODO b/TODO deleted file mode 100644 index 9db5336..0000000 --- a/TODO +++ /dev/null @@ -1,16 +0,0 @@ -* chklinks does not support authentication yet. W3C-LinkChecker - have support on this. As a workaround, You can use the syntax - http://user:pass@some.where.com/some/path for Basic Authentication, - but this does not work on Digest Authentication. This practice is - not encouraged, too. Your password would be visable to anyone on - this system using ps, including hidden intruders. Also what you - type in your shell will be saved to your shell history file. - -* mailto: URLs should be supported by checking the validity of its - DNS/MX record. - -* Local file checking has only been tested on Unix and MS-Windows. - More platforms should be tested, especially VMS and Mac. - -* chklinks does not obey Crawl-delay: in robots.txt yet. This is a - problem in WWW::RobotRules, but not chklinks itself. diff --git a/TODO.zh-cn b/TODO.zh-cn deleted file mode 100644 index 6ba9151..0000000 --- a/TODO.zh-cn +++ /dev/null @@ -1,15 +0,0 @@ -* chklinks 还不支援登入帐号密码的功能。 W3C-LinkChecker 有支援这个功能 - 。若不是 Digest 登入,只是 Basic 登入,你可以先用像是 - http://user:pass@some.where.com/some/path 的语法登入。不过请不要这样 - 做。任何人只要用 ps 指令,就看得到密码。如果这时候系统有入侵者偷偷溜 - 进来,也可以看得到。而且这样写在指令中的密码,也会存在你的指令记录档 - 中。 - -* 应该可以支援 mailto: 的网址,检查其 DNS/MX 是否可用。 Bastian - Kleineidam 的 linkchecker 有支援这个功能。 - -* 一般档案的支援目前只在 Unix 和 MS-Windows 上测试过,还需要在其它作业 - 系统如 VMS 及 Mac 上测试能不能运作。 - -* chklinks 尚未遵守 robots.txt 的 Crawl-delay: 规则。不过这是 - WWW::RobotRules 的问题,不是 chklinks 的问题。 diff --git a/TODO.zh-tw b/TODO.zh-tw deleted file mode 100644 index 9200f6d..0000000 --- a/TODO.zh-tw +++ /dev/null @@ -1,15 +0,0 @@ -* chklinks 临ぃや穿祅眀腹盞絏 W3C-LinkChecker Τや穿硂 - 璝ぃ琌 Digest 祅琌 Basic 祅﹑ノ钩琌 - http://user:pass@some.where.com/some/path 粂猭祅ぃ筁叫ぃ璶硂妓 - 暗ヴ璶ノ ps 碞眔盞絏狦硂╰参Τ獻敖敖啡 - 秈ㄓ眔τ硂妓糶い盞絏穦﹑癘魁郎 - い - -* 莱赣や穿 mailto: 呼浪琩ㄤ DNS/MX 琌ノ Bastian - Kleineidam  linkchecker Τや穿硂 - -* 郎や穿ヘ玡 Unix ㎝ MS-Windows 代刚筁临惠璶ㄤウ穨 - ╰参 VMS の Mac 代刚ぃ笲 - -* chklinks ﹟ゼ宽 robots.txt  Crawl-delay: 砏玥ぃ筁硂琌 - WWW::RobotRules 拜肈ぃ琌 chklinks 拜肈 diff --git a/chklinks b/chklinks index 75849c8..3e723ba 100755 --- a/chklinks +++ b/chklinks @@ -1,22 +1,21 @@ #! /usr/bin/perl -w # chklinks: A non-threaded Perl link checker -# Copyright (c) 2003-2007 imacat. -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . +# Copyright (c) 2003-2021 imacat. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. -# First written: 2003-04-12 +# First written: 2003/4/12 use 5.006; use strict; @@ -38,43 +37,43 @@ use URI::Escape qw(uri_escape uri_unescape); sub main(); sub parse_args(); sub check_links($); -sub fetch_redir($); -sub fetch_noredir($); +sub fetch_redirect($); +sub fetch_no_redirect($); sub get_links($$); sub proc_link_val($$); sub is_excluded($); sub get_ua($); sub get_target($); -sub noreq_key($); +sub no_req_key($); sub rep_uri($); -use vars qw($THIS_FILE $VERSION $VERBOSE); +our ($THIS_FILE, $VERSION, $VERBOSE); $THIS_FILE = basename($0); $VERSION = "3.09"; $VERBOSE = 1; -use vars qw(@STARTS $RECURSIVE $PARENT $NOREMOTE @EXCLUDES); -use vars qw($UASTR %UA %TARGETS %URIS %REFS $COOKIE_JAR); -use vars qw($LOCAL_TARGET @LOCALS %LFOUND $STARTDIR @REMOTES %RFOUND); -use vars qw($TOTAL $SUCCESS %NOREQ_HOSTS %ALLOWED_SCHEMES); -$UASTR = "$THIS_FILE-robot/$VERSION (using " . (LWP::RobotUA->can("_agent")? +our (@STARTS, $RECURSIVE, $PARENT, $IS_LOCAL, @EXCLUDES); +our ($UA_STR, %UA, %TARGETS, %URIS, %REFS, $COOKIE_JAR); +our ($LOCAL_TARGET, @LOCALS, %LOCAL_FOUND, $START_DIR, @REMOTES, %REMOTE_FOUND); +our ($TOTAL, $SUCCESS, %NO_REQ_HOSTS, %ALLOWED_SCHEMES); +$UA_STR = "$THIS_FILE-robot/$VERSION (using " . (LWP::RobotUA->can("_agent")? LWP::RobotUA->_agent: "libwww-perl/" . $LWP::VERSION) . ")"; %UA = qw(); %TARGETS = qw(); %URIS = qw(); %REFS = qw(); -$COOKIE_JAR = new HTTP::Cookies; -%NOREQ_HOSTS = qw(); +$COOKIE_JAR = HTTP::Cookies->new; +%NO_REQ_HOSTS = qw(); $RECURSIVE = 1; $PARENT = 0; -$NOREMOTE = 0; +$IS_LOCAL = 0; @EXCLUDES = qw(); %ALLOWED_SCHEMES = map { $_ => 1 } qw(http https ftp file gopher); -use vars qw($VERMSG $SHORTHELP $HELPMSG); -$VERMSG = "$THIS_FILE v$VERSION by imacat "; -$SHORTHELP = "Try `$THIS_FILE --help' for more information."; -$HELPMSG = << "EOT"; +our ($VER_MSG, $SHORT_HELP, $HELP_MSG); +$VER_MSG = "$THIS_FILE v$VERSION by imacat "; +$SHORT_HELP = "Try `$THIS_FILE --help' for more information."; +$HELP_MSG = << "EOT"; Usage: $THIS_FILE [options] url1 [url2 [url3 ...]] Check links on the specific website. @@ -102,7 +101,7 @@ EOT main; exit 0; -# main: Main program +# Main program sub main() { local ($_, %_); @@ -117,7 +116,7 @@ sub main() { return; } -# parse_args: Parse the arguments +# Parse the arguments sub parse_args() { local ($_, %_); @@ -129,16 +128,16 @@ sub parse_args() { "recursive|r"=>sub { $RECURSIVE = 1; }, "below|b"=>sub { $PARENT = 0; }, "parent|p"=>sub { $PARENT = 1; }, - "local|l"=>sub { $NOREMOTE = 1; }, - "span|s"=>sub { $NOREMOTE = 0; }, + "local|l"=>sub { $IS_LOCAL = 1; }, + "span|s"=>sub { $IS_LOCAL = 0; }, "exclude|e=s"=>sub { unshift @EXCLUDES, "-" . $_[1]; }, "include|i=s"=>sub { unshift @EXCLUDES, "+" . $_[1]; }, "debug|d+"=>\$VERBOSE, "quiet|q"=>sub { $VERBOSE-- if $VERBOSE > 0; }, - "help|h"=>sub { print $HELPMSG; exit 0; }, - "version|v"=>sub { print "$VERMSG\n"; exit 0; }); + "help|h"=>sub { print $HELP_MSG; exit 0; }, + "version|v"=>sub { print "$VER_MSG\n"; exit 0; }); }; - die "$THIS_FILE: $@$SHORTHELP\n" if $@ ne ""; + die "$THIS_FILE: $@$SHORT_HELP\n" if $@ ne ""; # Show progress $| = 1 if $VERBOSE > 2; @@ -147,10 +146,10 @@ sub parse_args() { # Arguments are URLs @STARTS = qw(); while (@ARGV > 0) { - my ($uri, $uritext); - $uritext = shift @ARGV; - $uri = new URI($uritext); - # Single letter scheme is assumed to be a volumn label + my ($uri, $address); + $address = shift @ARGV; + $uri = URI->new($address); + # Single letter scheme is assumed to be a volume label # This is for MSWin32 $uri->scheme(undef) if defined $uri->scheme && $uri->scheme =~ /^[a-z]$/i; # URI without a scheme is assumed to be a local file @@ -161,19 +160,19 @@ sub parse_args() { $base = getcwd; $base =~ s/\/$//; $base =~ s/^\///; - $base = new URI("file://localhost/$base/"); - $uri = new URI(join("/", File::Spec->splitdir($uritext))); + $base = URI->new("file://localhost/$base/"); + $uri = URI->new(join("/", File::Spec->splitdir($address))); $uri = $uri->abs($base); # Systems without symbolic links -- we assume rel2abs() is trustworthy. # Like MSWin32 } else { - $uri = new URI("file://localhost/" . join("/", File::Spec->splitdir(File::Spec->rel2abs($uritext)))); + $uri = URI->new("file://localhost/" . join("/", File::Spec->splitdir(File::Spec->rel2abs($address)))); $uri->scheme("file"); $uri->host("localhost"); } } if (!exists $ALLOWED_SCHEMES{$uri->scheme}) { - warn "$THIS_FILE: WARNING: $uritext: Skipping URI with unsupported scheme " . $uri->scheme . "\n" + warn "$THIS_FILE: WARNING: $address: Skipping URI with unsupported scheme " . $uri->scheme . "\n" if $VERBOSE > 0; next; } @@ -181,20 +180,20 @@ sub parse_args() { if ($uri->scheme eq "file") { $uri->host("localhost") if !defined $uri->host || $uri->host eq ""; if ($uri->host ne "localhost") { - warn "$THIS_FILE: WARNING: $uritext: Skipping file URI that is not on localhost\n" + warn "$THIS_FILE: WARNING: $address: Skipping file URI that is not on localhost\n" if $uri->host ; next; } # schemes other than file require a host } else { if (!defined $uri->host || $uri->host eq "") { - warn "$THIS_FILE: WARNING: $uritext: Skipping URI without a host\n" + warn "$THIS_FILE: WARNING: $address: Skipping URI without a host\n" if $VERBOSE > 0; next; } } if ($uri->path eq "") { - warn "$THIS_FILE: WARNING: $uritext: URI not canonical\n" + warn "$THIS_FILE: WARNING: $address: URI not canonical\n" if $VERBOSE > 0; $uri->path("/"); } @@ -202,35 +201,35 @@ sub parse_args() { # Use its canonical form $uri = $uri->canonical; if (exists $URIS{$uri->as_string}) { - warn "$THIS_FILE: WARNING: Skipping duplicated URI $uritext\n" + warn "$THIS_FILE: WARNING: Skipping duplicated URI $address\n" if $VERBOSE > 0; next; } $URIS{$uri->as_string} = $uri; push @STARTS, $uri->as_string; } - die "$THIS_FILE: Please specify the URL to check\n$SHORTHELP\n" + die "$THIS_FILE: Please specify the URL to check\n$SHORT_HELP\n" if @STARTS == 0; return; } -# check_links: Check links from an URL +# Check links from an URL sub check_links($) { local ($_, %_); my ($start, $page, $doc); $start = $_[0]; @LOCALS = qw($start); - %LFOUND = ($start => 1); + %LOCAL_FOUND = ($start => 1); $LOCAL_TARGET = get_target $start; @REMOTES = qw(); ($TOTAL, $SUCCESS) = (0, 0); - $STARTDIR = $URIS{$start}->path; - $STARTDIR =~ s/[^\/]+$//; + $START_DIR = $URIS{$start}->path; + $START_DIR =~ s/[^\/]+$//; $page = $start; - ($page, $doc) = fetch_redir $page; + ($page, $doc) = fetch_redirect $page; return if !defined $doc; get_links $doc, $page; while (@LOCALS > 0 || @REMOTES > 0) { @@ -238,7 +237,7 @@ sub check_links($) { if (@LOCALS > 0) { @LOCALS = sort @LOCALS; $page = $LOCALS[0]; - ($page, $doc) = fetch_redir $page; + ($page, $doc) = fetch_redirect $page; # Skip the failed request next if !defined $doc; # Skip if non-recursive @@ -251,7 +250,7 @@ sub check_links($) { } else { @REMOTES = sort @REMOTES; $page = $REMOTES[0]; - fetch_redir $page; + fetch_redirect $page; # We are not parsing remote documents } } @@ -261,68 +260,68 @@ sub check_links($) { return; } -# fetch_redir: Fetch a document and deal with redirection -sub fetch_redir($) { +# Fetch a document and deal with redirection +sub fetch_redirect($) { local ($_, %_); - my ($orig, $redir, $doc, $referer); + my ($orig, $redirect, $doc, $referer); $orig = $_[0]; while (1) { - ($doc, $redir) = fetch_noredir $orig; + ($doc, $redirect) = fetch_no_redirect $orig; # No more redirection - return ($orig, $doc) if !defined $redir; + return ($orig, $doc) if !defined $redirect; # Redirection target was scheduled - return ($orig, undef) if exists $LFOUND{$redir} || exists $RFOUND{$redir}; + return ($orig, undef) if exists $LOCAL_FOUND{$redirect} || exists $REMOTE_FOUND{$redirect}; # Record the referer - $REFS{$redir} = [] if !exists $REFS{$redir}; + $REFS{$redirect} = [] if !exists $REFS{$redirect}; $referer = [rep_uri $orig]; push @$referer, @{${$REFS{$orig}}[0]} if exists $REFS{$orig}; - push @{$REFS{$redir}}, $referer; + push @{$REFS{$redirect}}, $referer; # Process the next - $orig = $redir; + $orig = $redirect; } } -# fetch_noredir: Fetch a document without redirection -sub fetch_noredir($) { - my ($uritext, $uri, $ua, $r, $urirep); - $uritext = $_[0]; +# Fetch a document without redirection +sub fetch_no_redirect($) { + my ($address, $uri, $ua, $r, $addr_report); + $address = $_[0]; # Remove it from the list - if (get_target($uritext) eq $LOCAL_TARGET) { + if (get_target($address) eq $LOCAL_TARGET) { shift @LOCALS; } else { shift @REMOTES; } # Set the target URI to report - $urirep = rep_uri $uritext; - $urirep .= " (Referer: " . join(", ", map join(" -> ", reverse @$_), @{$REFS{$uritext}}) . ")" - if exists $REFS{$uritext}; + $addr_report = rep_uri $address; + $addr_report .= " (Referer: " . join(", ", map join(" -> ", reverse @$_), @{$REFS{$address}}) . ")" + if exists $REFS{$address}; # Add the counter $TOTAL++; # Skip if this host has returned 503 Service Unavailable previously - if (exists $NOREQ_HOSTS{noreq_key $uritext}) { - $_ = $urirep; + if (exists $NO_REQ_HOSTS{no_req_key $address}) { + $_ = $addr_report; $_ .= " skipped for service unavailable in previous request to " - . $NOREQ_HOSTS{noreq_key $uritext} + . $NO_REQ_HOSTS{no_req_key $address} if $VERBOSE > 0; print "$_\n"; return (undef, undef); } - $uri = $URIS{$uritext}; + $uri = $URIS{$address}; - print STDERR "Requesting $urirep... " if $VERBOSE > 2; - $ua = get_ua $uritext; + print STDERR "Requesting $addr_report... " if $VERBOSE > 2; + $ua = get_ua $address; # HTTP or HTTPS -- use HTTP::Request for more sophisticated configuration if ($uri->scheme =~ /^https?$/) { my ($request, $w, $sigwarn); - $request = new HTTP::Request(GET => $uri->as_string); + $request = HTTP::Request->new(GET => $uri->as_string); # Set the referer - $request->header("Referer", ${${$REFS{$uritext}}[0]}[0]) - if exists $REFS{$uritext}; + $request->header("Referer", ${${$REFS{$address}}[0]}[0]) + if exists $REFS{$address}; # Gracefully deal with robots.txt warnings $sigwarn = $SIG{"__WARN__"}; undef $w; @@ -334,7 +333,7 @@ sub fetch_noredir($) { if ($w =~ /^RobotRules <[^\n]+>: Unexpected line: /) { # Skip malformed robots.txt warnings on remote sites # We are assumed to have no control on the remote sites - if (get_target($uritext) ne $LOCAL_TARGET) { + if (get_target($address) ne $LOCAL_TARGET) { # Skip warnings about Crawl-delay: # As of writing this, WWW::RobotRules 1.33 in libwww-perl 5.805 @@ -380,90 +379,88 @@ sub fetch_noredir($) { # 3XX Redirect } elsif (grep($r->code == $_, (301, 302, 303, 307)) > 0) { - my ($is_full_uri, $ruri, $rtarget); + my ($is_full_uri, $redirect_uri); # Redirect without location is an error if (!defined $r->header("Location")) { - print STDERR "$urirep " . $r->status_line . ": Redirect without location\n"; + print STDERR "$addr_report " . $r->status_line . ": Redirect without location\n"; return (undef, undef); } - $ruri = new URI($r->header("Location")); + $redirect_uri = URI->new($r->header("Location")); # Deal with non-canonical location $is_full_uri = 1; # Non-absolute location should be warned - if (!defined $ruri->scheme) { + if (!defined $redirect_uri->scheme) { $is_full_uri = 0; - $ruri->scheme($uri->scheme); + $redirect_uri->scheme($uri->scheme); } # Skip schemes that are not supported return (undef, undef) if !exists $ALLOWED_SCHEMES{$uri->scheme}; - if (!defined $ruri->host || $ruri->host eq "") { + if (!defined $redirect_uri->host || $redirect_uri->host eq "") { $is_full_uri = 0; - $ruri->host($uri->host); + $redirect_uri->host($uri->host); } - if ($ruri->path eq "") { + if ($redirect_uri->path eq "") { $is_full_uri = 0; - $ruri->path("/"); + $redirect_uri->path("/"); } - warn "$THIS_FILE: WARNING: $uritext: " . $r->status_line . ": " + warn "$THIS_FILE: WARNING: $address: " . $r->status_line . ": " . "Location not canonical: " . $r->header("Location") . "\n" if !$is_full_uri && $VERBOSE > 1; - $ruri->fragment(undef); + $redirect_uri->fragment(undef); # Use its canonical form - $ruri = $ruri->canonical; + $redirect_uri = $redirect_uri->canonical; # Save it - $URIS{$ruri->as_string} = $ruri if !exists $URIS{$ruri->as_string}; + $URIS{$redirect_uri->as_string} = $redirect_uri if !exists $URIS{$redirect_uri->as_string}; # 301 Moved Permanently should be treated as an error, because we need # to change the reference from now on. if ($r->code == 301) { - $_ = $urirep; - $_ .= " " . $r->status_line . ": " . $ruri->as_string + $_ = $addr_report; + $_ .= " " . $r->status_line . ": " . $redirect_uri->as_string if $VERBOSE > 0; print "$_\n"; - return (undef, $ruri->as_string); + return (undef, $redirect_uri->as_string); } $SUCCESS++; # Warn when not quiet - print "$urirep " . $r->status_line . ": " . $ruri->as_string . "\n" + print "$addr_report " . $r->status_line . ": " . $redirect_uri->as_string . "\n" if $VERBOSE > 1; - return (undef, $ruri->as_string); + return (undef, $redirect_uri->as_string); # Bad response that we cannot go on } elsif (grep($r->code == $_, (400, 403, 404, 410, 500)) > 0) { - $_ = $urirep; + $_ = $addr_report; $_ .= " " . $r->status_line if $VERBOSE > 0; print "$_\n"; return (undef, undef); # Bad response that we should not keep requesting on a same server } elsif ($r->code == 503) { - $_ = $urirep; + $_ = $addr_report; $_ .= " " . $r->status_line if $VERBOSE > 0; print "$_\n"; - $NOREQ_HOSTS{noreq_key $uritext} = $uritext; + $NO_REQ_HOSTS{no_req_key $address} = $address; return (undef, undef); # Unable to process } else { # Unable to process - print "$urirep " . $r->status_line . ": Unable to process this response\n"; + print "$addr_report " . $r->status_line . ": Unable to process this response\n"; return (undef, undef); } - - return; } -# get_links: Parse the document and get the links inside +# Parse the document and get the links inside sub get_links($$) { local ($_, %_); my ($html, $base, $parser); ($html, $base) = @_; - $parser = new HTML::LinkExtor; + $parser = HTML::LinkExtor->new; $parser->utf8_mode(1) if $] >= 5.008 && $HTML::Parser::VERSION >= 3.40; $parser->parse($html); @_ = qw(); @@ -475,13 +472,13 @@ sub get_links($$) { return; } -# proc_link_val: Process a found link value +# Process a found link value sub proc_link_val($$) { local ($_, %_); my ($base, $uri); ($_, $base) = @_; - $uri = new URI($_); + $uri = URI->new($_); # Make it canonical $uri = $uri->abs($URIS{$base}) if !defined $uri->scheme; @@ -521,29 +518,29 @@ sub proc_link_val($$) { # Local if (get_target($uri->as_string) eq $LOCAL_TARGET) { # Skip found URLs - return if exists $LFOUND{$uri->as_string}; + return if exists $LOCAL_FOUND{$uri->as_string}; # Skip parent directories - return if !$PARENT && $uri->path !~ /^$STARTDIR/; + return if !$PARENT && $uri->path !~ /^$START_DIR/; push @LOCALS, $uri->as_string; - $LFOUND{$uri->as_string} = 1; + $LOCAL_FOUND{$uri->as_string} = 1; # Remote } else { # No remote - return if $NOREMOTE; + return if $IS_LOCAL; # Skip found URLs - return if exists $RFOUND{$uri->as_string}; + return if exists $REMOTE_FOUND{$uri->as_string}; push @REMOTES, $uri->as_string; - $RFOUND{$uri->as_string} = 1; + $REMOTE_FOUND{$uri->as_string} = 1; } return; } -# is_excluded: If this page is excluded +# If this page is excluded sub is_excluded($) { local ($_, %_); - my ($page, $path, $excpath, $match); + my ($page, $path, $match); $page = $_[0]; foreach (@EXCLUDES) { @@ -562,7 +559,7 @@ sub is_excluded($) { return 0; } -# get_ua: Return a user agent for the request +# Return a user agent for the request sub get_ua($) { local ($_, %_); $_ = $_[0]; @@ -574,8 +571,8 @@ sub get_ua($) { return $UA{$_} if exists $UA{$_}; # Create a new user agent - $UA{$_} = new LWP::RobotUA( - "agent" => $UASTR, + $UA{$_} = LWP::RobotUA->new( + "agent" => $UA_STR, "from" => (getlogin or getpwuid $> or $> or $THIS_FILE) . "@" . hostname, "keep_alive" => 1, @@ -587,19 +584,19 @@ sub get_ua($) { return $UA{$_}; } -# get_target: Return the target of the request +# Return the target of the request sub get_target($) { local ($_, %_); - my ($uritext, $uri, $scheme, $user, $pass, $host, $port); - $uritext = $_[0]; + my ($address, $uri, $scheme, $user, $pass, $host, $port); + $address = $_[0]; - die sprintf("%s %s", (caller 2)[1,2]) if !defined $uritext; + die sprintf("%s %s", (caller 2)[1,2]) if !defined $address; # Target cached - return $TARGETS{$uritext} if exists $TARGETS{$uritext}; + return $TARGETS{$address} if exists $TARGETS{$address}; # Construct the target of our request - $uri = $URIS{$uritext}; + $uri = $URIS{$address}; $scheme = $uri->scheme; if (!$uri->can("userinfo") || !defined($_ = $uri->userinfo)) { ($user, $pass) = (undef, undef); @@ -616,7 +613,7 @@ sub get_target($) { undef $port if defined $_ && $_ eq $port; # Construct the target URI - $uri = new URI(""); + $uri = URI->new(""); $uri->scheme($scheme); undef $_; if (defined $user) { @@ -628,17 +625,17 @@ sub get_target($) { $uri->port($port) if defined $port; # Cache it - $TARGETS{$uritext} = $uri->canonical; - return $TARGETS{$uritext}; + $TARGETS{$address} = $uri->canonical; + return $TARGETS{$address}; } -# noreq_key: Obtain the key to check if we should keep requesting on this server -sub noreq_key($) { +# Obtain the key to check if we should keep requesting on this server +sub no_req_key($) { local ($_, %_); my $uri; $_ = $_[0]; - $uri = new URI(""); + $uri = URI->new(""); $uri->scheme($URIS{$_}->scheme); $uri->host(inet_aton($URIS{$_}->host)); $uri->port($URIS{$_}->port) if $URIS{$_}->can("port"); @@ -646,13 +643,13 @@ sub noreq_key($) { return $uri->canonical->as_string; } -# rep_uri: Report an URI, a wrapper to URI->as_string that clean the file scheme +# Report an URI, a wrapper to URI->as_string that clean the file scheme sub rep_uri($) { local ($_, %_); $_ = $_[0]; $_ = $_->as_string if ref($_) =~ /^URI\b/; return $_ unless s/^file:\/\///; - # Have something simular to a volumn ID, for MSWin32 + # Have something similar to a volume ID, for MSWin32 s/^\/([a-z]:)/$1/i; return File::Spec->catdir(split /\//, $_); } @@ -669,24 +666,23 @@ chklinks - A non-threaded Perl link checker =head1 DESCRIPTION -F is a non-threaded Perl link checker. It helps finding +F is a non-threaded Perl link checker. It helps to find broken links on your website. F differs from C in that F is non- -threaded. It does not raises many simultaneously connections for its +threaded. It does not raise many simultaneously connections for its job. It won't run out of the resources and crash your system in a moment. This is certainly more desirable for most webmasters and users. -F follows F rules. If you disallow robots -from your website and experience problems, you need to allow -F. Add the following lines to your F file to -allow F: +F respects F. If you disallow robots from your +website and experience problems, you need to allow F. Add +the following lines to your F file to allow F: User-agent: chklinks Disallow: -F uses L and support the +F uses L and supports the following schemes: http, https, ftp, gopher and file. You can also specify a local file. (To use https, you need to install L. This is the requirement of @@ -698,43 +694,43 @@ F supports cookies. =over -=item -1,--onelevel +=item -1, --onelevel Check the links on this page and stops. -=item -r,--recursive +=item -r, --recursive Recursively check through this website. This is the default. -=item -b,--below +=item -b, --below Only check the links below this directory. This is the default. -=item -p,--parent +=item -p, --parent Trace back to the parent directories. -=item -l,--local +=item -l, --local Only check the links on this same host. -=item -s,--span +=item -s, --span Check the links to other hosts (without recursion). This is the default. -=item -e,--exclude path +=item -e, --exclude path Exclude this path. Check for their existence but not check the links on them, just like they are on a foreign site. Multiple C<--exclude> are OK. -=item -i,--include path +=item -i, --include path Include this path. An opposite of C<--exclude> that cancels its effect. The latter specified has a higher priority. -=item -d,--debug +=item -d, --debug Display debug messages. Multiple C<--debug> to debug more. @@ -743,11 +739,11 @@ Display debug messages. Multiple C<--debug> to debug more. Disable debug messages. An opposite that cancels the effect of C<--debug>. -=item -h,--help +=item -h, --help Display the help message and exit. -=item -v,--version +=item -v, --version Output version information and exit. @@ -776,11 +772,11 @@ for a L patch on this. =head1 BUGS F does not support authentication yet. W3C-LinkChecker -have support on this. As a workaround, You can use the syntax +supports this. As a workaround, You can use the syntax http://user:pass@some.where.com/some/path for Basic Authentication, but this does not work on Digest Authentication. This practice is -not encouraged. Your password would be visable to anyone on this -system using F, including hidden intruders. Also what you type +not encouraged. Your password would be visible to anyone on this +system using F, including hidden intruders. Also, what you type in your shell will be saved to your shell history file. C URLs should be supported by checking the validity of its @@ -792,19 +788,8 @@ platforms should be tested, especially VMS and Mac. =head1 SUPPORT -F is hosted on SourceForge, CPAN and Tavern IMACAT's. For -the latest infomation, see http://chklinks.sourceforge.net/ , -http://sourceforge.net/projects/chklinks/ , -http://search.cpan.org/dist/chklinks/ or -http://www.imacat.idv.tw/tech/chklinks.html . - -F has a user discussion mailing list hosted at -SourceForge: chklinks-users@lists.sourceforge.net . It is a mailman -mailing list. For infomation on how to join or leave, see: -http://lists.sourceforge.net/lists/listinfo/chklinks-users . -Alternatively, you can send a mail to: -chklinks-users-request@lists.sourceforge.net with the subject C -for a list of available commands. +The F project is hosted on GitHub. Address your issues on +the GitHub issue tracker https://github.com/imacat/chklinks/issues. =head1 SEE ALSO @@ -820,19 +805,18 @@ imacat . =head1 COPYRIGHT -Copyright (c) 2003-2007 imacat. +Copyright (c) 2003-2021 imacat. -This program is free software: you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at -This program is distributed in the hope that it will be useful, -but I; without even the implied warranty of -I or I. See the -GNU General Public License for more details. + http://www.apache.org/licenses/LICENSE-2.0 -You should have received a copy of the GNU General Public License -along with this program. If not, see L. +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. =cut diff --git a/chklinks.en.html b/chklinks.en.html deleted file mode 100644 index 877a4ae..0000000 --- a/chklinks.en.html +++ /dev/null @@ -1,477 +0,0 @@ - - - - - - - - - - - - - - - -chklinks Version 3.09 - - - -
- 正體中文 | - 简体中文 | - English -
-
- - -
- - -

chklinks Version 3.09

- - -

What’s New?

- - -
- -
2007-12-06
- -
-

chklinks version 3.09 is released. Fixed the bug on systems like MS-Windows that does not have getpwuid(). Download chklinks version 3.09.

-
- - -
2007-12-05
- -
-

chklinks version 3.08 is released. There are several documentation fixes. Download chklinks version 3.08.

-
- - -
2007-12-05
- -
-

chklinks version 3.07 is released. Required Perl version number compatible to older versions, to work with the Perl 5.10 warning. License updated to GPLv3. Download chklinks version 3.07.

-
- - -
2007-06-08
- -
-

chklinks version 3.06 is released. Test suite fixes. Download chklinks version 3.06.

-
- - -
2007-06-07
- -
-

chklinks version 3.05 is released. Fixed problem with Perl version earlier than 5.8 where UTF-8 mode is not available. Download chklinks version 3.05.

-
- - -
2007-06-06
- -
-

chklinks version 3.04 is released. Documentation fixes. Download chklinks version 3.04.

-
- - -
2007-06-06
- -
-

chklinks version 3.03 is released. Fixed the raw UTF-8 warning with HTML::Parser. Added support for building with Module::Build. Download chklinks version 3.03.

-
- - -
2006-06-02
- -
-

chklinks version 3.02 is released. The digital signature is corrected. Download chklinks version 3.02.

-
- - -
2006-05-31
- -
-

chklinks version 3.01 is released. This fixed a missing prerequisites in Makefile.PL. HTML documents are returned. Download chklinks version 3.01.

-
- - -
2006-05-30
- -
-

chklinks version 3.00 is released. It uses HTML::LinkExtor to parse the page and LWP::RobotUA to make requests. More URL schemes other than http are supported. Cookies are supported. robots.txt rules are respected. Download chklinks version 3.00.

-
- - -
2005-10-02
- -
-

Website style adjustment. WCAG Accessibility designs are added. <hr />s are replaced by CSS borders for accessibility reason.

-
- - -
2005-04-27
- -
-

The text 繁體中文 on the website is corrected to 正體中文.

-
- - -
2003-05-26
- -
-

chklinks version 2.02 is released. The default changed from one-level to recursive. This is more desirable in most cases. Download chklinks version 2.02.

-
- - -
2003-05-25
- -
-

chklinks version 2.01 is released. An installer, accessary files and a POD document are added. Download chklinks version 2.01.

-
- - -
2003-05-25
- -
-

chklinks version 2.0.0 is released. This is the first public release uploaded onto SourceForge. Only the main script file is available. Download chklinks version 2.0.0.

-
- - -
2003-05-19
- -
-

SourceForge project space approved.

-
- - -
2003-05-18
- -
-

Requesting a SourceForge project space.

-
- -
- - -

Description

- -

chklinks is a non-threaded Perl link checker. It helps finding broken links on your website.

- -

chklinks differs from linkchecker in that chklinks is non-threaded. It does not raises many simultaneously connections for its job. It won’t run out of the resources and crash your system in a moment. This is certainly more desirable for most webmasters and users.

- -

chklinks follows robots.txt rules. If you disallow robots from your website and experience problems, you need to allow chklinks. Add the following lines to your robots.txt file to allow chklinks:

- -
-User-agent: chklinks
-Disallow:
-
- -

chklinks uses LWP::RobotUA and support the following schemes: http, https, ftp, gopher and file. You can also specify a local file. (To use https, you need to install Crypt::SSLeay. This is the requirement of -LWP::RobotUA.)

- -

chklinks supports cookies.

- - -

System Requirement

- -
    -
  1. Perl, version 5.6 or above. I have not successfully run this on earlier versions. Please tell me if you can. You can run perl -v to see your current Perl version. Perl is distributed with most Unix now. If not, or if you have an older version of Perl, you can download and install/upgrade it from Perl website. If you are using MS-Windows, you can download and install ActiveState ActivePerl.

  2. - -
  3. Required Perl modules:

    - -
    -
    URI
    - -
    -

    This is used to parse and process the found URLs. You can download and install URI from the CPAN archive, or install it with the CPAN shell by running cpan URI, or install it with the CPANPLUS shell by running cpanp i URI. Debian/Ubandu Linux users can install it by running apt-get install liburi-perl. Red Hat/Fedora/CentOS Linux users can install it by running yum install perl-URI. FreeBSD users can install it by running ports install p5-URI. ActivePerl users can install it by running ppm install URI.

    -
    - -
    HTML::LinkExtor
    - -
    -

    This is used to extract links from the web pages. HTML::LinkExtor is contained in the HTML-Parser distribution. You can download and install HTML::LinkExtor from the CPAN archive, or install it with the CPAN shell by running cpan HTML::LinkExtor, or install it with the CPANPLUS shell by running cpanp i HTML::LinkExtor. Debian/Ubandu Linux users can install it by running apt-get install libhtml-parser-perl. Red Hat/Fedora/CentOS Linux users can install it by running yum install perl-HTML-Parser. FreeBSD users can install it by running ports install p5-HTML-Parser. ActivePerl users can install it by running ppm install HTML::LinkExtor.

    -
    - -
    LWP::RobotUA
    - -
    -

    This is used to request web pages. LWP::RobotUA is contained in the libwww-perl distribution. You can download and install LWP::RobotUA from the CPAN archive, or install it with the CPAN shell by running cpan LWP::RobotUA, or install it with the CPANPLUS shell by running cpanp i LWP::RobotUA. Debian/Ubandu Linux users can install it by running apt-get install libwww-perl. Red Hat/Fedora/CentOS Linux users can install it by running yum install perl-libwww-perl. FreeBSD users can install it by running ports install p5-libwww. ActivePerl users can install it by running ppm install LWP::RobotUA.

    -
    -
    - -

    If you install chklinks with the CPAN or CPAN shell, the above shall be automatically installed.

    -
  4. - - -
  5. Optional Perl modules:

    - -
    -
    Crypt::SSLeay
    - -
    -

    This is needed for LWP::RobotUA to support HTTPS. You can download and install Config::General from the CPAN archive, or install it with the CPAN shell by running cpan Config::General, or install it with the CPANPLUS shell by running cpanp i Config::General. Debian/Ubandu Linux users can install it by running apt-get install libconfig-general-perl. Red Hat/Fedora/CentOS Linux users can install it by running yum install perl-Config-General. FreeBSD users can install it by running ports install p5-Config-General. ActiveState does not host the PPM build of Crypt::SSLeay for ActivePerl due to the Canadian Federal Government requirement. However, ActivePerl users can still install it from another repository, by running ppm install http://theoryx5.uwinnipeg.ca/ppms/Crypt-SSLeay.ppd.

    -
    -
    -
  6. -
- - -

Download

- -

chklinks’s official websites is at…

- - - -

You can always download the newest version of chklinks from…

- - - -

imacat’s PGP public key is at…

- - - - -

Install

- -

Install with ExtUtils::MakeMaker

- -

chklinks uses standard Perl installation with ExtUtils::MakeMaker. Follow these steps:

- -
-% perl Makefile.PL
-% make
-% make test
-% make install
-
- -

When running make install, make sure you have the priviledge to write to the installation location. This usually requires the root priviledge.

- -

If you are using ActivePerl under MS-Windows, you should use nmake instead of make. nmake can be obtained from the Microsoft FTP site.

- -

If you want to install into another location, you can set the PREFIX. For example, to install into your home when you are not root:

- -
-% perl Makefile.PL PREFIX=/home/jessica
-
- -

Refer to the docuemntation of ExtUtils::MakeMaker for more installation options (by running perldoc ExtUtils::MakeMaker).

- - -

Install with Module::Build

- -

You can install with Module::Build instead, if you prefer. Follow these steps:

- -
-% perl Build.PL
-% ./Build
-% ./Build test
-% ./Build install
-
- -

When running ./Build install, make sure you have the priviledge to write to the installation location. This usually requires the root priviledge.

- -

If you want to install into another location, you can set the --prefix. For example, to install into your home when you are not root:

- -
-% perl Build.PL --prefix=/home/jessica
-
- -

Refer to the docuemntation of Module::Build for more installation options (by running perldoc Module::Build).

- - -

Options

- -
-./chklinks [options] URL1 [URL2 [URL3 …]]
-./chklinks [-h|-v]
-
- - -
-
-1,--onelevel
- -
-

Check the links on this page and stops.

-
- - -
-r,--recursive
- -
-

Recursively check through this website. This is the default.

-
- - -
-b,--below
- -
-

Only check the links below this directory. This is the default.

-
- - -
-p,--parent
- -
-

Trace back to the parent directories.

-
- - -
-l,--local
- -
-

Only check the links on this same host.

-
- - -
-s,--span
- -
-

Check the links to other hosts (without recursion). This is the default.

-
- - -
-e,--exclude path
- -
-

Exclude this path. Check for their existence but not check the links on them, just like they are on a foreign site. Multiple --exclude are OK.

-
- - -
-i,--include path
- -
-

Include this path. An opposite of --exclude that cancels its effect. The latter specified has a higher priority.

-
- - -
-d,--debug
- -
-

Display debug messages. Multiple --debug to debug more.

-
- - -
-q,--quiet
- -
-

Disable debug messages. An opposite that cancels the effect of --debug.

-
- - -
-h, --help
- -
-

Display the help message and exit.

-
- - -
-v, --version
- -
-

Output version information and exit.

-
- - -
URL1, URL2, URL3
- -
-

The URLs of the websites to check against.

-
-
- - -

Notes

- -
    -
  • chklinks does not obey Crawl-delay: in robots.txt yet. This is a problem in WWW::RobotRules, but not chklinks itself.

  • - -
  • If you encounter warnings like this:

    - -
    -
    Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/share/perl5/LWP/Protocol.pm line 114.
    -
    - -

    This is an issue of LWP::Protocol version ≤ 1.43 (in libwww-perl version ≤ 5.805) when working with HTML::Parser version ≥ 3.40 and Perl version ≥ 5.8. This issue is solved in LWP::Protocol version ≥ 1.46 (in libwww-perl version ≥ 5.806). You can upgrade your LWP::Protocol to the current version. If you cannot upgrade it, see CPAN RT Bug#20274 for an LWP::Protocol patch on this.

    -
  • -
- - -

See Also

- -

LWP::UserAgent, LWP::RobotUA, WWW::RobotRules, URI, HTML::LinkExtor, Bastian Kleineidam’s linkchecker and W3C-LinkChecker checklink.

- - -

Copyright

- -

Copyright © 2003-2007 imacat. All rights reserved.

- -

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

- -

This program is distributed in the hope that it will be useful, but without any warranty; without even the implied warranty of merchantability or fitness for a particular purpose. See the GNU General Public License for more details.

- -

You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.

- - -

Release Notes

- -

Please read the NEWS for the new functions and bug fixes.

- - -

Support

- -

chklinks is hosted on SourceForge, CPAN and Tavern IMACAT’s. For the latest infomation, see

- - - -

There is a chklinks mailing list hosted at SourceForge. Please submit your questions, suggestions or bug reports there. It is a Mailman mailing list. For more information, see the chklinks mailing list page. Alternatively, you can send a mail to the e-mail command mailbox with the subject help for a list of available e-mail commands.

- -
- - -
- - - - diff --git a/chklinks.zh-cn.html b/chklinks.zh-cn.html deleted file mode 100644 index ac82ea4..0000000 --- a/chklinks.zh-cn.html +++ /dev/null @@ -1,477 +0,0 @@ - - - - - - - - - - - - - - - -chklinks 3.09 版 - - - -
- 正體中文 | - 简体中文 | - English -
-
- - -
- - -

chklinks 3.09 版

- - -

最新消息

- -
- -
2007-12-06
- -
-

chklinks 最新版本 3.09 。新版修正像 MS-Windows 之类不支援 getpwuid() 呼叫的作业系统的问题。下载 chklinks 3.09 版

-
- - -
2007-12-05
- -
-

chklinks 最新版本 3.08 。新版修正好几个说明文件的问题。下载 chklinks 3.08 版

-
- - -
2007-12-05
- -
-

chklinks 最新版本 3.07 。所需 Perl 版本号码改用相容於旧版的号码格式,以消除 Perl 5.10 的警告讯息。版权更新为 GPLv3下载 chklinks 3.07 版

-
- - -
2007-06-08
- -
-

chklinks 最新版本 3.06 。测试程式修正。下载 chklinks 3.06 版

-
- - -
2007-06-07
- -
-

chklinks 最新版本 3.05 。修正 Perl 5.8 版以前无 UTF-8 模式的问题。下载 chklinks 3.05 版

-
- - -
2007-06-06
- -
-

chklinks 最新版本 3.04 。修正说明文件。下载 chklinks 3.04 版

-
- - -
2007-06-06
- -
-

chklinks 最新版本 3.03 。修正 HTML::Parser 的原始 UTF-8 警告讯息,加上支援以 Module::Build 安装。下载 chklinks 3.03 版

-
- - -
2006-06-02
- -
-

chklinks 最新版本 3.02 。更正错误的数位签章。下载 chklinks 3.02 版

-
- - -
2006-05-31
- -
-

chklinks 最新版本 3.01 。修正 Makefile.PL 漏掉的相依模组,并把漏掉的 HTML 文件加回来。下载 chklinks 3.01 版

-
- - -
2006-05-30
- -
-

chklinks 最新版本 3.00 。改用 HTML::LinkExtor 解读网页并用 LWP::RobotUA 连线取得网页。支援 http 外的其它网址格式。支援网站的 Cookies 。遵守 robots.txt 设定的规则。下载 chklinks 3.00 版

-
- - -
2005-10-02
- -
-

网站样式调整,加上无障碍网页的设计,以 CSS 边框代替 <hr /> ,以符合无障碍网页空间的要求。

-
- - -
2005-04-27
- -
-

网站上的繁体中文字样更正为正体中文

-
- - -
2003-05-26
- -
-

chklinks 最新版本 2.02 。预设由检查本页就好,改为检查整个网站。这样比较符合大多数的需求。下载 chklinks 2.02 版

-
- - -
2003-05-25
- -
-

chklinks 最新版本 2.01 。加上安装程式、附加档案与 POD 说明档。下载 chklinks 2.01 版

-
- - -
2003-05-25
- -
-

chklinks 最新版本 2.0.0 。首次公开上传到 SourceForge 。只有主程式。下载 chklinks 2.0.0 版

-
- - -
2003-05-19
- -
-

SourceForge 专案通过。

-
- - -
2003-05-18
- -
-

申请 SourceForge 专案。

-
- -
- - -

说明

- -

chklinks 是单执行绪的 Perl 连结检查程式,用来检查网站上的超连结有没有疏漏。

- -

chklinkslinkchecker 不同之处在於,chklinks 不是多执行绪的程式。 chklinks 检查时,不会同时启动一大堆连线同步检查,耗尽系统资源,导致当机。对大多数网管和使用者而言,这样做安全得多。

- -

chklinks 遵守 robots.txt 设定的规则。若你的网站拒绝自动网页程式,导致 chklinks 无法执行,请在你的 robots.txt ,加入下列两行,放行 chklinks

- -
-User-agent: chklinks
-Disallow:
-
- -

chklinks 使用 LWP::RobotUA 连线,支援下列通讯协定: httphttpsftpgopherfilechklinks 也可以检查一般的档案。(若要使用 https 通讯协定,需先安装 Crypt::SSLeay 。这是 LWP::RobotUA 的需求。)

- -

chklinks 支援网站的 Cookies

- - -

系统需求

- -
    -
  1. Perl 5.6 或以上。我还没有在更早的版本上成功执行过。若你可以在更早的版本上执行,请告诉我。你可以输入 perl -v 查询你目前的 Perl 版本。目前大多数的 Unix 系统都有 Perl 。如果你没有 Perl 或需要升级,可以到 Perl 网站下载安装最新版 Perl 。若你是用 MS-Windows ,可以下载安装 ActiveState 公司的 ActivePerl

  2. - -
  3. 需搭配的 Perl 模组:

    - -
    -
    URI
    - -
    -

    这是解析、处理网址用的。你可以CPAN 模组库下载安装 URI ,或用 CPAN Shell 执行 cpan URI 安装,或用 CPANPLUS Shell 执行 cpanp i URI 安装。若你是 Debian/Ubandu Linux 使用者,可以执行 apt-get install liburi-perl 安装。若你是 Red Hat/Fedora/CentOS Linux 使用者,可以执行 yum install perl-URI 安装。若你是 FreeBSD 使用者,可以执行 ports install p5-URI 安装。若你是 ActivePerl 使用者,可以执行 ppm install URI 安装。

    -
    - -
    HTML::LinkExtor
    - -
    -

    这是由网页里找出连结用的。 HTML::LinkExtorHTML-Parser 中的模组。你可以CPAN 模组库下载安装 HTML::LinkExtor ,或用 CPAN Shell 执行 cpan HTML::LinkExtor 安装,或用 CPANPLUS Shell 执行 cpanp i HTML::LinkExtor 安装。若你是 Debian/Ubandu Linux 使用者,可以执行 apt-get install libhtml-parser-perl 安装。若你是 Red Hat/Fedora/CentOS Linux 使用者,可以执行 yum install perl-HTML-Parser 安装。若你是 FreeBSD 使用者,可以执行 ports install p5-HTML-Parser 安装。若你是 ActivePerl 使用者,可以执行 ppm install HTML::LinkExtor 安装。

    -
    - -
    LWP::RobotUA
    - -
    -

    这是抓取网页用的。 LWP::RobotUAlibwww-perl 中的模组。你可以CPAN 模组库下载安装 LWP::RobotUA ,或用 CPAN Shell 执行 cpan LWP::RobotUA 安装,或用 CPANPLUS Shell 执行 cpanp i LWP::RobotUA 安装。若你是 Debian/Ubandu Linux 使用者,可以执行 apt-get install libwww-perl 安装。若你是 Red Hat/Fedora/CentOS Linux 使用者,可以执行 yum install perl-libwww-perl 安装。若你是 FreeBSD 使用者,可以执行 ports install p5-libwww 安装。若你是 ActivePerl 使用者,可以执行 ppm install LWP::RobotUA 安装。

    -
    -
    - -

    若你由 CPANCPANPLUS Shell 安装 chklinks ,会自动帮你安装以上所需的模组。

    -
  4. - -
  5. 选配的 Perl 模组:

    - -
    -
    Crypt::SSLeay
    - -
    -

    这是要让 LWP::RobotUA 支援 HTTPS 的功能。你可以CPAN 模组库下载安装 Crypt::SSLeay ,或用 CPAN Shell 执行 cpan Crypt::SSLeay 安装,或用 CPANPLUS Shell 执行 cpanp i Crypt::SSLeay 安装。若你是 Debian/Ubandu Linux 使用者,可以执行 apt-get install libcrypt-ssleay-perl 安装。若你是 Red Hat/Fedora/CentOS Linux 使用者,可以执行 yum install perl-Crypt-SSLeay 安装。若你是 FreeBSD 使用者,可以执行 ports install p5-Crypt-SSLeay 安装。因加拿大联邦政府的规定, ActiveState 公司无法提供 Crypt::SSLeayActivePerl PPM 套件安装。不过若你是 ActivePerl 使用者,还是可以改由其它套件库,执行 ppm install http://theoryx5.uwinnipeg.ca/ppms/Crypt-SSLeay.ppd 安装。

    -
    -
    -
  6. -
- - -

下载

- -

chklinks 的官方网站在:

- - - -

最新版 chklinks 可由下列位址下载:

- - - -

依玛猫的 PGP 公钥在:

- - - - -

安装

- -

ExtUtils::MakeMaker 安装

- -

chklinksPerl 标准的 ExtUtils::MakeMaker 安装,程序如下:

- -
-% perl Makefile.PL
-% make
-% make test
-% make install
-
- -

make install 前,请先确认你有在安装目录存档的权限。通常这时候要切换为 root ,才能安装存档。

- -

若你是用 MS-Windows 下的 ActivePerlmake 请改用 nmakenmake 可 -由微软的 FTP 站下载

- -

若要安装到其它地方,请设定好 PREFIX 。例如,一般使用者,要安装在自己的目录下时:

- -
-% perl Makefile.PL PREFIX=/home/jessica
-
- -

要知道更多安装选项的细节,请参阅 ExtUtils::MakeMaker 的说明(请执行 perldoc ExtUtils::MakeMaker )。

- - -

Module::Build 安装

- -

若你喜欢,也可以用 Module::Build 安装,程序如下:

- -
-% perl Build.PL
-% ./Build
-% ./Build test
-% ./Build install
-
- -

./Build install 前,请先确认你有在安装目录存档的权限。通常这时候要切换为 root ,才能安装存档。

- -

若要安装到其它地方,请设定好 --prefix 。例如,一般使用者,要安装在自己的目录下时:

- -
-% perl Build.PL --prefix=/home/jessica
-
- -

要知道更多安装选项的细节,请参阅 Module::Build 的说明(请执行 perldoc Module::Build )。

- - -

命令列参数

- -
-./chklinks [参数] 网址1 [网址2 [网址3 …]]
-./chklinks [-h|-v]
-
- - -
-
-1,--onelevel
- -
-

检查本页就好,不继续查下去。

-
- - -
-r,--recursive
- -
-

检查完整个网站。预设是 --recursive

-
- - -
-b,--below
- -
-

只检查该目录下的连结。预设是 --below

-
- - -
-p,--parent
- -
-

上溯到全站的连结。

-
- - -
-l,--local
- -
-

只检查站上的连结,不检查站外连结。

-
- - -
-s,--span
- -
-

检查站外的连结(但不会查下去)。预设是 --span

-
- - -
-e,--exclude 路径
- -
-

排除该路迳。把该路径下的档案当成站外连结,只检查能不能连,不深入查下去。你可以指定很多个 --exclude

-
- - -
-i,--include 路径
- -
-

包含该路迳。和 --exclude 效果相反,用来抵销 --exclude 。排后面的优先处理。

-
- - -
-d,--debug
- -
-

显示详细的执行讯息。越多个 --debug ,讯息越详细。

-
- - -
-q,--quiet
- -
-

关闭执行讯息。和 --debug 效果相反,用来抵销 --debug

-
- - -
-h, --help
- -
-

显示程式说明。

-
- - -
-v, --version
- -
-

显示程式版本。

-
- -
网址1, 网址2, 网址3
- -
-

要检查的网站网址。

-
-
- - -

注意事项

- -
    -
  • chklinks 尚未遵守 robots.txtCrawl-delay: 规则。不过这是 WWW::RobotRules 的问题,不是 chklinks 的问题。

  • - -
  • 若出现以下警告:

    - -
    -
    Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/share/perl5/LWP/Protocol.pm line 114.
    -
    - -

    这是 LWP::Protocol 1.43 版或之前的版本( libwww-perl 5.805 版或之前的版本),碰上 HTML::Parser 3.40 版或之后的版本及 Perl 5.8 版或之后的版本时,产生的问题。 LWP::Protocol 1.46 版以后( libwww-perl 5.806 版以后),已解决这个问题。请升级到最新版的 LWP::Protocol 。若你因故无法升级,请参阅 CPAN RT Bug#20274 报告,取得 LWP::Protocol 的修补程式。

    -
  • -
- - -

参考资料

- -

LWP::UserAgentLWP::RobotUAWWW::RobotRulesURIHTML::LinkExtorBastian KleineidamlinkcheckerW3C-LinkChecker checklink

- - -

版权声明

- -

版权所有 © 2003-2007 依玛猫。

- -

本程式是自由软体,您可以遵照自由软体基金会 (Free Software Foundation) 出版的 GNU 通用公共许可证条款 (GNU General Public License) 第三版来修改和重新发布这一程式,或者自由选择使用任何更新的版本。

- -

发布这一程式的目的是希望它有用,但没有任何担保。甚至没有适合特定目的而隐含的担保。更详细的情况请参阅 GNU 通用公共许可证

- -

您应该已经和程式一起收到一份 GNU 通用公共许可证的副本。如果还没有,参阅<http://www.gnu.org/licenses/>

- - -

版本纪录

- -

请阅读 NEWS 档,查看程式的演变、新增的功能和修补的错误。

- - -

支援协助

- -

chklinks 网站架在 SourceForgeCPAN旅舍依玛。索取最新资讯,请驾临:

- - - -

SourceForge 上有一个 chklinks 的邮件通讯 。使用上的问题、建议或错误回报,请提到通讯上讨论。它是 Mailman 的邮件通讯。若要加入,请到 chklinks 邮件通讯的网页 。你也可以写信到 E-mail 指令信箱,标题填上 help ,索取 E-mail 指令说明。

- -
- - -
- - - - diff --git a/chklinks.zh-tw.html b/chklinks.zh-tw.html deleted file mode 100644 index 0c24ade..0000000 --- a/chklinks.zh-tw.html +++ /dev/null @@ -1,480 +0,0 @@ - - - - - - - - - - - - - - - -chklinks 3.09  - - - -
- 羉砰いゅ | - 简蔨いゅ | - English -
-
- - -
- - -

chklinks 3.09 

- - -

程穝

- -
- -
2007-12-06
- -
-

chklinks 程穝セ 3.09 穝タ钩 MS-Windows ぇ摸ぃや穿 getpwuid() ㊣穨╰参拜肈更 chklinks 3.09 

-
- - -
2007-12-05
- -
-

chklinks 程穝セ 3.08 穝タ碭弧ゅン拜肈更 chklinks 3.08 

-
- - -
2007-12-05
- -
-

chklinks 程穝セ 3.07 ┮惠 Perl セ腹絏эノ甧侣腹絏Α埃 Perl 5.10 牡癟舦穝 GPLv3更 chklinks 3.07 

-
- - -
2007-06-08
- -
-

chklinks 程穝セ 3.06 代刚祘Αタ更 chklinks 3.06 

-
- - -
2007-06-07
- -
-

chklinks 程穝セ 3.05 タ Perl 5.8 玡礚 UTF-8 家Α拜肈更 chklinks 3.05 

-
- - -
2007-06-06
- -
-

chklinks 程穝セ 3.04 タ弧ゅン更 chklinks 3.04 

-
- - -
2007-06-06
- -
-

chklinks 程穝セ 3.03 タ HTML::Parser ﹍ UTF-8 牡癟や穿 Module::Build 杆更 chklinks 3.03 

-
- - -
2006-06-02
- -
-

chklinks 程穝セ 3.02 タ岿粇计帽彻更 chklinks 3.02 

-
- - -
2006-05-31
- -
-

chklinks 程穝セ 3.01 タ Makefile.PL 簗奔ㄌ家舱р簗奔 HTML ゅンㄓ更 chklinks 3.01 

-
- - -
2006-05-30
- -
-

chklinks 程穝セ 3.00 эノ HTML::LinkExtor 秆弄呼ノ LWP::RobotUA 硈絬眔呼や穿 http ㄤウ呼Αや穿呼 Cookies 宽 robots.txt 砞﹚砏玥更 chklinks 3.00 

-
- - -
2005-10-02
- -
-

呼妓Α秸俱礚毁锚呼砞璸 CSS 娩蠢 <hr /> 才礚毁锚呼丁璶―

-
- - -
2005-04-27
- -
-

呼羉砰いゅ妓タタ砰いゅ

-
- - -
2003-05-26
- -
-

chklinks 程穝セ 2.02 箇砞パ浪琩セ碞э浪琩俱呼硂妓ゑ耕才计惠―更 chklinks 2.02 

-
- - -
2003-05-25
- -
-

chklinks 程穝セ 2.01 杆祘Α郎籔 POD 弧郎更 chklinks 2.01 

-
- - -
2003-05-25
- -
-

chklinks 程穝セ 2.0.0 Ωそ秨肚 SourceForge Τ祘Α更 chklinks 2.0.0 

-
- - -
2003-05-19
- -
-

SourceForge 盡硄筁

-
- - -
2003-05-18
- -
-

ビ叫 SourceForge 盡

-
- -
- - -

弧

- -

chklinks 琌虫磅︽狐 Perl 硈挡浪琩祘Αノㄓ浪琩呼禬硈挡Τ⊿Τ波簗

- -

chklinkslinkchecker ぃぇ矪chklinks ぃ琌磅︽狐祘Α chklinks 浪琩ぃ穦币笆帮硈絬˙浪琩荷╰参戈方旧璓讽诀癸计呼恨㎝ㄏノτē硂妓暗眔

- -

chklinks 宽 robots.txt 砞﹚砏玥璝﹑呼┶荡笆呼祘Α旧璓 chklinks 礚猭磅︽叫﹑ robots.txt ㄢ︽︽ chklinks

- -
-User-agent: chklinks
-Disallow:
-
- -

chklinks ㄏノ LWP::RobotUA 硈絬や穿硄癟﹚ httphttpsftpgopherfilechklinks 浪琩郎璝璶ㄏノ https 硄癟﹚惠杆 Crypt::SSLeay 硂琌 LWP::RobotUA 惠―

- -

chklinks や穿呼 Cookies

- - -

╰参惠―

- -
    -
  1. Perl 5.6 ┪и临⊿ΤΝセΘ磅︽筁璝﹑Νセ磅︽叫禗и﹑块 perl -v 琩高﹑ヘ玡 Perl セヘ玡计 Unix ╰参常Τ Perl 狦﹑⊿Τ Perl ┪惠璶狜 Perl 呼更杆程穝 Perl 璝﹑琌ノ MS-Windows 更杆 ActiveState そ ActivePerl

  2. - -
  3. 惠穎皌 Perl 家舱

    - -
    -
    URI
    - -
    -

    硂琌秆猂矪瞶呼ノ﹑CPAN 家舱畐更杆 URI ┪ノ CPAN Shell 磅︽ cpan URI 杆┪ノ CPANPLUS Shell 磅︽ cpanp i URI 杆璝﹑琌 Debian/Ubandu Linux ㄏノ磅︽ apt-get install liburi-perl 杆璝﹑琌 Red Hat/Fedora/CentOS Linux ㄏノ磅︽ yum install perl-URI 杆璝﹑琌 FreeBSD ㄏノ磅︽ ports install p5-URI 杆璝﹑琌 ActivePerl ㄏノ磅︽ ppm install URI 杆

    -
    - -
    HTML::LinkExtor
    - -
    -

    硂琌パ呼т硈挡ノ HTML::LinkExtorHTML-Parser い家舱﹑CPAN 家舱畐更杆 HTML::LinkExtor ┪ノ CPAN Shell 磅︽ cpan HTML::LinkExtor 杆┪ノ CPANPLUS Shell 磅︽ cpanp i HTML::LinkExtor 杆璝﹑琌 Debian/Ubandu Linux ㄏノ磅︽ apt-get install libhtml-parser-perl 杆璝﹑琌 Red Hat/Fedora/CentOS Linux ㄏノ磅︽ yum install perl-HTML-Parser 杆璝﹑琌 FreeBSD ㄏノ磅︽ ports install p5-HTML-Parser 杆璝﹑琌 ActivePerl ㄏノ磅︽ ppm install HTML::LinkExtor 杆

    -
    - -
    LWP::RobotUA
    - -
    -

    硂琌ъ呼ノ LWP::RobotUAlibwww-perl い家舱﹑CPAN 家舱畐更杆 LWP::RobotUA ┪ノ CPAN Shell 磅︽ cpan LWP::RobotUA 杆┪ノ CPANPLUS Shell 磅︽ cpanp i LWP::RobotUA 杆璝﹑琌 Debian/Ubandu Linux ㄏノ磅︽ apt-get install libwww-perl 杆璝﹑琌 Red Hat/Fedora/CentOS Linux ㄏノ磅︽ yum install perl-libwww-perl 杆璝﹑琌 FreeBSD ㄏノ磅︽ ports install p5-libwww 杆璝﹑琌 ActivePerl ㄏノ磅︽ ppm install LWP::RobotUA 杆

    -
    -
    - -

    璝﹑パ CPANCPANPLUS Shell 杆 chklinks 穦笆腊﹑杆┮惠家舱

    -
  4. - -
  5. 匡皌 Perl 家舱

    - -
    -
    Crypt::SSLeay
    - -
    -

    硂琌璶琵 LWP::RobotUA や穿 HTTPS ﹑CPAN 家舱畐更杆 Crypt::SSLeay ┪ノ CPAN Shell 磅︽ cpan Crypt::SSLeay 杆┪ノ CPANPLUS Shell 磅︽ cpanp i Crypt::SSLeay 杆璝﹑琌 Debian/Ubandu Linux ㄏノ磅︽ apt-get install libcrypt-ssleay-perl 杆璝﹑琌 Red Hat/Fedora/CentOS Linux ㄏノ磅︽ yum install perl-Crypt-SSLeay 杆璝﹑琌 FreeBSD ㄏノ磅︽ ports install p5-Crypt-SSLeay 杆羛ü現┎砏﹚ ActiveState そ礚猭矗ㄑ Crypt::SSLeayActivePerl PPM 甅ン杆ぃ筁璝﹑琌 ActivePerl ㄏノ临琌эパㄤウ甅ン畐磅︽ ppm install http://theoryx5.uwinnipeg.ca/ppms/Crypt-SSLeay.ppd 杆

    -
    -
    -
  6. -
- - -

更

- -

chklinks ﹛よ呼

- - - -

程穝 chklinks パ更

- - - -

ㄌ嚎窟 PGP そ芲

- - - - -

杆

- -

ExtUtils::MakeMaker 杆

- -

chklinksPerl 夹非 ExtUtils::MakeMaker 杆祘

- -
-% perl Makefile.PL
-% make
-% make test
-% make install
-
- -

make install 玡叫絋粄﹑Τ杆ヘ魁郎舦硄盽硂璶ち传 root 杆郎

- -

璝﹑琌ノ MS-Windows  ActivePerlmake 叫эノ nmakenmake  -パ稬硁 FTP 更

- -

璝璶杆ㄤウよ叫砞﹚ PREFIX ㄒㄏノ璶杆ヘ魁

- -
-% perl Makefile.PL PREFIX=/home/jessica
-
- -

璶笵杆匡兜灿竊叫把綷 ExtUtils::MakeMaker 弧叫磅︽ perldoc ExtUtils::MakeMaker 

- - -

Module::Build 杆

- -

璝﹑尺舧ノ Module::Build 杆祘

- -
-% perl Build.PL
-% ./Build
-% ./Build test
-% ./Build install
-
- -

./Build install 玡叫絋粄﹑Τ杆ヘ魁郎舦硄盽硂璶ち传 root 杆郎

- -

璝璶杆ㄤウよ叫砞﹚ --prefix ㄒㄏノ璶杆ヘ魁

- -
-% perl Build.PL --prefix=/home/jessica
-
- -

璶笵杆匡兜灿竊叫把綷 Module::Build 弧叫磅︽ perldoc Module::Build 

- - -

㏑把计

- -
-./chklinks [把计] 呼1 [呼2 [呼3 …]]
-./chklinks [-h|-v]
-
- - -
-
-1,--onelevel
- -
-

浪琩セ碞ぃ膥尿琩

-
- - -
-r,--recursive
- -
-

浪琩Ч俱呼箇砞琌 --recursive

-
- - -
-b,--below
- -
-

浪琩赣ヘ魁硈挡箇砞琌 --below

-
- - -
-p,--parent
- -
-

饭硈挡

-
- - -
-l,--local
- -
-

浪琩硈挡ぃ浪琩硈挡

-
- - -
-s,--span
- -
-

浪琩硈挡ぃ穦琩箇砞琌 --span

-
- - -
-e,--exclude 隔畖
- -
-

逼埃赣隔硍р赣隔畖郎讽Θ硈挡浪琩ぃ硈ぃ瞏琩﹑﹚ --exclude

-
- - -
-i,--include 隔畖
- -
-

赣隔硍㎝ --exclude 狦はノㄓ╄綪 --exclude 逼纔矪瞶

-
- - -
-d,--debug
- -
-

陪ボ冈灿磅︽癟禫 --debug 癟禫冈灿

-
- - -
-q,--quiet
- -
-

闽超磅︽癟㎝ --debug 狦はノㄓ╄綪 --debug

-
- - -
-h, --help
- -
-

陪ボ祘Α弧

-
- - -
-v, --version
- -
-

陪ボ祘Αセ

-
- -
呼1, 呼2, 呼3
- -
-

璶浪琩呼呼

-
-
- - -

猔種ㄆ兜

- -
    -
  • chklinks ﹟ゼ宽 robots.txtCrawl-delay: 砏玥ぃ筁硂琌 WWW::RobotRules 拜肈ぃ琌 chklinks 拜肈

  • - -
  • 璝瞷牡

    - -
    -
    Parsing of undecoded UTF-8 will give garbage when decoding entities at /usr/share/perl5/LWP/Protocol.pm line 114.
    -
    - -

    硂琌 LWP::Protocol 1.43 ┪ぇ玡セ libwww-perl 5.805 ┪ぇ玡セ窱 HTML::Parser 3.40 ┪ぇセの Perl 5.8 ┪ぇセ玻ネ拜肈 LWP::Protocol 1.46  libwww-perl 5.806 秆∕硂拜肈叫狜程穝 LWP::Protocol 璝﹑珿礚猭狜叫把綷 CPAN RT Bug#20274 厨眔 LWP::Protocol 干祘Α

    -
  • -
- - -

把σ戈

- -

LWP::UserAgentLWP::RobotUAWWW::RobotRulesURIHTML::LinkExtorBastian KleineidamlinkcheckerW3C-LinkChecker checklink

- - -

舦羘

- -

舦┮Τ © 2003-2007 ㄌ嚎窟

- -

セ祘Α琌パ硁砰眤宽酚パ硁砰膀穦 (Free Software Foundation)  GNU 硄ノそ砛靡兵蹿 (GNU General Public License) 材ㄓэ㎝穝祇硂祘Α┪パ匡拒ㄏノヴ穝セ

- -

祇硂祘Αヘ琌辨ウΤノ⊿Τヴ踞玂⊿Τ続疭﹚ヘτ留踞玂冈灿薄猵叫把綷 GNU 硄ノそ砛靡

- -

眤莱赣竒㎝祘Α癬Μ GNU 硄ノそ砛靡捌セ狦临⊿Τ把綷<http://www.gnu.org/licenses/>

- - -

セ魁

- -

叫綷弄 NEWS 郎琩祘Α簍跑穝糤㎝干岿粇

- - -

や穿

- -

chklinks 呼琜 SourceForgeCPANㄌ嚎程穝戈癟叫緍羬

- - - -

SourceForge Τ chklinks 秎ン硄癟 ㄏノ拜肈某┪岿粇厨叫矗硄癟癚阶ウ琌 Mailman 秎ン硄癟璝璶叫 chklinks 秎ン硄癟呼 ﹑糶獺 E-mail 獺絚夹肈恶 help  E-mail 弧

- -
- - -
- - - - diff --git a/fdl.txt b/fdl.txt deleted file mode 100644 index 4a0fe1c..0000000 --- a/fdl.txt +++ /dev/null @@ -1,397 +0,0 @@ - GNU Free Documentation License - Version 1.2, November 2002 - - - Copyright (C) 2000,2001,2002 Free Software Foundation, Inc. - 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - -0. PREAMBLE - -The purpose of this License is to make a manual, textbook, or other -functional and useful document "free" in the sense of freedom: to -assure everyone the effective freedom to copy and redistribute it, -with or without modifying it, either commercially or noncommercially. -Secondarily, this License preserves for the author and publisher a way -to get credit for their work, while not being considered responsible -for modifications made by others. - -This License is a kind of "copyleft", which means that derivative -works of the document must themselves be free in the same sense. It -complements the GNU General Public License, which is a copyleft -license designed for free software. - -We have designed this License in order to use it for manuals for free -software, because free software needs free documentation: a free -program should come with manuals providing the same freedoms that the -software does. But this License is not limited to software manuals; -it can be used for any textual work, regardless of subject matter or -whether it is published as a printed book. We recommend this License -principally for works whose purpose is instruction or reference. - - -1. APPLICABILITY AND DEFINITIONS - -This License applies to any manual or other work, in any medium, that -contains a notice placed by the copyright holder saying it can be -distributed under the terms of this License. Such a notice grants a -world-wide, royalty-free license, unlimited in duration, to use that -work under the conditions stated herein. The "Document", below, -refers to any such manual or work. Any member of the public is a -licensee, and is addressed as "you". You accept the license if you -copy, modify or distribute the work in a way requiring permission -under copyright law. - -A "Modified Version" of the Document means any work containing the -Document or a portion of it, either copied verbatim, or with -modifications and/or translated into another language. - -A "Secondary Section" is a named appendix or a front-matter section of -the Document that deals exclusively with the relationship of the -publishers or authors of the Document to the Document's overall subject -(or to related matters) and contains nothing that could fall directly -within that overall subject. (Thus, if the Document is in part a -textbook of mathematics, a Secondary Section may not explain any -mathematics.) The relationship could be a matter of historical -connection with the subject or with related matters, or of legal, -commercial, philosophical, ethical or political position regarding -them. - -The "Invariant Sections" are certain Secondary Sections whose titles -are designated, as being those of Invariant Sections, in the notice -that says that the Document is released under this License. If a -section does not fit the above definition of Secondary then it is not -allowed to be designated as Invariant. The Document may contain zero -Invariant Sections. If the Document does not identify any Invariant -Sections then there are none. - -The "Cover Texts" are certain short passages of text that are listed, -as Front-Cover Texts or Back-Cover Texts, in the notice that says that -the Document is released under this License. A Front-Cover Text may -be at most 5 words, and a Back-Cover Text may be at most 25 words. - -A "Transparent" copy of the Document means a machine-readable copy, -represented in a format whose specification is available to the -general public, that is suitable for revising the document -straightforwardly with generic text editors or (for images composed of -pixels) generic paint programs or (for drawings) some widely available -drawing editor, and that is suitable for input to text formatters or -for automatic translation to a variety of formats suitable for input -to text formatters. A copy made in an otherwise Transparent file -format whose markup, or absence of markup, has been arranged to thwart -or discourage subsequent modification by readers is not Transparent. -An image format is not Transparent if used for any substantial amount -of text. A copy that is not "Transparent" is called "Opaque". - -Examples of suitable formats for Transparent copies include plain -ASCII without markup, Texinfo input format, LaTeX input format, SGML -or XML using a publicly available DTD, and standard-conforming simple -HTML, PostScript or PDF designed for human modification. Examples of -transparent image formats include PNG, XCF and JPG. Opaque formats -include proprietary formats that can be read and edited only by -proprietary word processors, SGML or XML for which the DTD and/or -processing tools are not generally available, and the -machine-generated HTML, PostScript or PDF produced by some word -processors for output purposes only. - -The "Title Page" means, for a printed book, the title page itself, -plus such following pages as are needed to hold, legibly, the material -this License requires to appear in the title page. For works in -formats which do not have any title page as such, "Title Page" means -the text near the most prominent appearance of the work's title, -preceding the beginning of the body of the text. - -A section "Entitled XYZ" means a named subunit of the Document whose -title either is precisely XYZ or contains XYZ in parentheses following -text that translates XYZ in another language. (Here XYZ stands for a -specific section name mentioned below, such as "Acknowledgements", -"Dedications", "Endorsements", or "History".) To "Preserve the Title" -of such a section when you modify the Document means that it remains a -section "Entitled XYZ" according to this definition. - -The Document may include Warranty Disclaimers next to the notice which -states that this License applies to the Document. These Warranty -Disclaimers are considered to be included by reference in this -License, but only as regards disclaiming warranties: any other -implication that these Warranty Disclaimers may have is void and has -no effect on the meaning of this License. - - -2. VERBATIM COPYING - -You may copy and distribute the Document in any medium, either -commercially or noncommercially, provided that this License, the -copyright notices, and the license notice saying this License applies -to the Document are reproduced in all copies, and that you add no other -conditions whatsoever to those of this License. You may not use -technical measures to obstruct or control the reading or further -copying of the copies you make or distribute. However, you may accept -compensation in exchange for copies. If you distribute a large enough -number of copies you must also follow the conditions in section 3. - -You may also lend copies, under the same conditions stated above, and -you may publicly display copies. - - -3. COPYING IN QUANTITY - -If you publish printed copies (or copies in media that commonly have -printed covers) of the Document, numbering more than 100, and the -Document's license notice requires Cover Texts, you must enclose the -copies in covers that carry, clearly and legibly, all these Cover -Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on -the back cover. Both covers must also clearly and legibly identify -you as the publisher of these copies. The front cover must present -the full title with all words of the title equally prominent and -visible. You may add other material on the covers in addition. -Copying with changes limited to the covers, as long as they preserve -the title of the Document and satisfy these conditions, can be treated -as verbatim copying in other respects. - -If the required texts for either cover are too voluminous to fit -legibly, you should put the first ones listed (as many as fit -reasonably) on the actual cover, and continue the rest onto adjacent -pages. - -If you publish or distribute Opaque copies of the Document numbering -more than 100, you must either include a machine-readable Transparent -copy along with each Opaque copy, or state in or with each Opaque copy -a computer-network location from which the general network-using -public has access to download using public-standard network protocols -a complete Transparent copy of the Document, free of added material. -If you use the latter option, you must take reasonably prudent steps, -when you begin distribution of Opaque copies in quantity, to ensure -that this Transparent copy will remain thus accessible at the stated -location until at least one year after the last time you distribute an -Opaque copy (directly or through your agents or retailers) of that -edition to the public. - -It is requested, but not required, that you contact the authors of the -Document well before redistributing any large number of copies, to give -them a chance to provide you with an updated version of the Document. - - -4. MODIFICATIONS - -You may copy and distribute a Modified Version of the Document under -the conditions of sections 2 and 3 above, provided that you release -the Modified Version under precisely this License, with the Modified -Version filling the role of the Document, thus licensing distribution -and modification of the Modified Version to whoever possesses a copy -of it. In addition, you must do these things in the Modified Version: - -A. Use in the Title Page (and on the covers, if any) a title distinct - from that of the Document, and from those of previous versions - (which should, if there were any, be listed in the History section - of the Document). You may use the same title as a previous version - if the original publisher of that version gives permission. -B. List on the Title Page, as authors, one or more persons or entities - responsible for authorship of the modifications in the Modified - Version, together with at least five of the principal authors of the - Document (all of its principal authors, if it has fewer than five), - unless they release you from this requirement. -C. State on the Title page the name of the publisher of the - Modified Version, as the publisher. -D. Preserve all the copyright notices of the Document. -E. Add an appropriate copyright notice for your modifications - adjacent to the other copyright notices. -F. Include, immediately after the copyright notices, a license notice - giving the public permission to use the Modified Version under the - terms of this License, in the form shown in the Addendum below. -G. Preserve in that license notice the full lists of Invariant Sections - and required Cover Texts given in the Document's license notice. -H. Include an unaltered copy of this License. -I. Preserve the section Entitled "History", Preserve its Title, and add - to it an item stating at least the title, year, new authors, and - publisher of the Modified Version as given on the Title Page. If - there is no section Entitled "History" in the Document, create one - stating the title, year, authors, and publisher of the Document as - given on its Title Page, then add an item describing the Modified - Version as stated in the previous sentence. -J. Preserve the network location, if any, given in the Document for - public access to a Transparent copy of the Document, and likewise - the network locations given in the Document for previous versions - it was based on. These may be placed in the "History" section. - You may omit a network location for a work that was published at - least four years before the Document itself, or if the original - publisher of the version it refers to gives permission. -K. For any section Entitled "Acknowledgements" or "Dedications", - Preserve the Title of the section, and preserve in the section all - the substance and tone of each of the contributor acknowledgements - and/or dedications given therein. -L. Preserve all the Invariant Sections of the Document, - unaltered in their text and in their titles. Section numbers - or the equivalent are not considered part of the section titles. -M. Delete any section Entitled "Endorsements". Such a section - may not be included in the Modified Version. -N. Do not retitle any existing section to be Entitled "Endorsements" - or to conflict in title with any Invariant Section. -O. Preserve any Warranty Disclaimers. - -If the Modified Version includes new front-matter sections or -appendices that qualify as Secondary Sections and contain no material -copied from the Document, you may at your option designate some or all -of these sections as invariant. To do this, add their titles to the -list of Invariant Sections in the Modified Version's license notice. -These titles must be distinct from any other section titles. - -You may add a section Entitled "Endorsements", provided it contains -nothing but endorsements of your Modified Version by various -parties--for example, statements of peer review or that the text has -been approved by an organization as the authoritative definition of a -standard. - -You may add a passage of up to five words as a Front-Cover Text, and a -passage of up to 25 words as a Back-Cover Text, to the end of the list -of Cover Texts in the Modified Version. Only one passage of -Front-Cover Text and one of Back-Cover Text may be added by (or -through arrangements made by) any one entity. If the Document already -includes a cover text for the same cover, previously added by you or -by arrangement made by the same entity you are acting on behalf of, -you may not add another; but you may replace the old one, on explicit -permission from the previous publisher that added the old one. - -The author(s) and publisher(s) of the Document do not by this License -give permission to use their names for publicity for or to assert or -imply endorsement of any Modified Version. - - -5. COMBINING DOCUMENTS - -You may combine the Document with other documents released under this -License, under the terms defined in section 4 above for modified -versions, provided that you include in the combination all of the -Invariant Sections of all of the original documents, unmodified, and -list them all as Invariant Sections of your combined work in its -license notice, and that you preserve all their Warranty Disclaimers. - -The combined work need only contain one copy of this License, and -multiple identical Invariant Sections may be replaced with a single -copy. If there are multiple Invariant Sections with the same name but -different contents, make the title of each such section unique by -adding at the end of it, in parentheses, the name of the original -author or publisher of that section if known, or else a unique number. -Make the same adjustment to the section titles in the list of -Invariant Sections in the license notice of the combined work. - -In the combination, you must combine any sections Entitled "History" -in the various original documents, forming one section Entitled -"History"; likewise combine any sections Entitled "Acknowledgements", -and any sections Entitled "Dedications". You must delete all sections -Entitled "Endorsements". - - -6. COLLECTIONS OF DOCUMENTS - -You may make a collection consisting of the Document and other documents -released under this License, and replace the individual copies of this -License in the various documents with a single copy that is included in -the collection, provided that you follow the rules of this License for -verbatim copying of each of the documents in all other respects. - -You may extract a single document from such a collection, and distribute -it individually under this License, provided you insert a copy of this -License into the extracted document, and follow this License in all -other respects regarding verbatim copying of that document. - - -7. AGGREGATION WITH INDEPENDENT WORKS - -A compilation of the Document or its derivatives with other separate -and independent documents or works, in or on a volume of a storage or -distribution medium, is called an "aggregate" if the copyright -resulting from the compilation is not used to limit the legal rights -of the compilation's users beyond what the individual works permit. -When the Document is included in an aggregate, this License does not -apply to the other works in the aggregate which are not themselves -derivative works of the Document. - -If the Cover Text requirement of section 3 is applicable to these -copies of the Document, then if the Document is less than one half of -the entire aggregate, the Document's Cover Texts may be placed on -covers that bracket the Document within the aggregate, or the -electronic equivalent of covers if the Document is in electronic form. -Otherwise they must appear on printed covers that bracket the whole -aggregate. - - -8. TRANSLATION - -Translation is considered a kind of modification, so you may -distribute translations of the Document under the terms of section 4. -Replacing Invariant Sections with translations requires special -permission from their copyright holders, but you may include -translations of some or all Invariant Sections in addition to the -original versions of these Invariant Sections. You may include a -translation of this License, and all the license notices in the -Document, and any Warranty Disclaimers, provided that you also include -the original English version of this License and the original versions -of those notices and disclaimers. In case of a disagreement between -the translation and the original version of this License or a notice -or disclaimer, the original version will prevail. - -If a section in the Document is Entitled "Acknowledgements", -"Dedications", or "History", the requirement (section 4) to Preserve -its Title (section 1) will typically require changing the actual -title. - - -9. TERMINATION - -You may not copy, modify, sublicense, or distribute the Document except -as expressly provided for under this License. Any other attempt to -copy, modify, sublicense or distribute the Document is void, and will -automatically terminate your rights under this License. However, -parties who have received copies, or rights, from you under this -License will not have their licenses terminated so long as such -parties remain in full compliance. - - -10. FUTURE REVISIONS OF THIS LICENSE - -The Free Software Foundation may publish new, revised versions -of the GNU Free Documentation License from time to time. Such new -versions will be similar in spirit to the present version, but may -differ in detail to address new problems or concerns. See -http://www.gnu.org/copyleft/. - -Each version of the License is given a distinguishing version number. -If the Document specifies that a particular numbered version of this -License "or any later version" applies to it, you have the option of -following the terms and conditions either of that specified version or -of any later version that has been published (not as a draft) by the -Free Software Foundation. If the Document does not specify a version -number of this License, you may choose any version ever published (not -as a draft) by the Free Software Foundation. - - -ADDENDUM: How to use this License for your documents - -To use this License in a document you have written, include a copy of -the License in the document and put the following copyright and -license notices just after the title page: - - Copyright (c) YEAR YOUR NAME. - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.2 - or any later version published by the Free Software Foundation; - with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. - A copy of the license is included in the section entitled "GNU - Free Documentation License". - -If you have Invariant Sections, Front-Cover Texts and Back-Cover Texts, -replace the "with...Texts." line with this: - - with the Invariant Sections being LIST THEIR TITLES, with the - Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST. - -If you have Invariant Sections without Cover Texts, or some other -combination of the three, merge those two alternatives to suit the -situation. - -If your document contains nontrivial examples of program code, we -recommend releasing these examples in parallel under your choice of -free software license, such as the GNU General Public License, -to permit their use in free software. diff --git a/pgpkey.asc b/pgpkey.asc deleted file mode 100644 index bd75349..0000000 --- a/pgpkey.asc +++ /dev/null @@ -1,40 +0,0 @@ ------BEGIN PGP PUBLIC KEY BLOCK----- -Version: GnuPG v1.4.1 (GNU/Linux) - -mQGiBD0kfGQRBADaGggoSHTZ8P17j92IMMxWPpML0TdvbhzW5iFF7a5th0xCn9od -pHVwc2YxuEulwDz0LJUx2IwwbttftHcJafcH51vk57Qq2+hvNAE1o9a/MWReMIwv -KfBi3Q1bVxWIjVPDbHd+ZUbbo0pozbfrHEaRPQ0qR+/ZgK5+V6WJiLElrwCgsCQy -FGfo72h5p46w7MrW4qSmalkD/RMcVmPkszF5J0N9pWlgcJ/fTYlMKIit3V/W/fru -L4KkUT3d9CMcJSBZrcVlXlDbPeBF8L7vl46NImd4xfnRKLwOuAy67Tld6CbC+UWz -rv6472rGetTTaj7iBH5nR62BQUmaLK6W6Q8vFOrqIBqXEz5iJ+RLYpIxH5M8gOz5 -7b7GBACIZaPaMVzIbTqnysDCgKEQqOyFbpgcGfSH52xH3XXeNrJhuenJFvBbeV8J -RgmKSnn1ZixFHJ261uGu5kOA1CQemNrTgZRaeHDu6mdZALdbxpLXp9DeOC/oTUWa -1O2xmAWcZZo+63s0MciC9zDrRjlNuGcVOiHZZLh9P9vEfoJos7Qu5L6d55Gq6LKT -IChpbWFjYXQpIDxpbWFjYXRAbWFpbC5pbWFjYXQuaWR2LnR3PoheBBMRAgAeBQJC -iLwmAhsDBgsJCAcDAgMVAgMDFgIBAh4BAheAAAoJEIvYLm8wuUtcmnYAnRQCNXWc -vgtk4CiTTBWqGWWZRjViAKCn/F6maM9R5RzuC1L5ER27f0AjbrkEDQQ9JHzZEBAA -owxPPj1TOZKGuav0eKopd8RrwFQ51P0FY85WyTAsCWg/KGcJIXFKwJ/r4U381iQd -z+16+E6oOzTIs/iwnkSKmfWx2M46uXdIa/VkLChZzHpCVDHeVICGE5sbECNS2gYD -CRx/Jl/FnXNaeaI0RZm3i4gf204bvqsPm+epI/BOW4cZmbkqSd4BuG2/i7y/BZzP -NhVseNVe2qhWFxs4Hj5S6y6xYSuuPLC4mZrkA7x1J9tq+wUt6z0mwIdRhEaK5iE5 -PB44XiwGKW02sLt5CQXDW/DbqXlyu6VP90iVjWLg0ftI28dULipw2n6u0DIGIxfL -i4dDf0gcYyqDF++aMWYTlB7a89Vt055dp7NC59VaqltW9DgKnxkiTUMxZ3HtqA67 -rwKtwKY3CQyuIYil31AQy0izi4fIu6MRznLtwHAfaqsB0Nej+kFl1XSUspe3P6ea -YzMs7on0X0KvPDWPo7AMz0Y/ex/XzYwR2+IzijTnaakH5TS7da0LKXb3FTV/PuIR -UgH3P/yOwRyOU4VLWqcyLxBJuMlX1WVz3UdNfHwRfm+jqPktP0qnQ9ZrFk3VEOGv -0hMvCeqj3Vw5CziYCTm3YiDG4OLPpUN3ByF944cUCYKwoGYEUKUf0vXPvUYdshqB -D49RyI0oy2nZstSt+iVefuCyWBYEyqIDu0eRGWY8FRMAAwUQAI/jMOnq6mP7mfbs -qq1ugXtx0r7cKNge0ebB/TA37ZLCo2UTdoxk/AsuGx1MK6kKJh3Zkxz89jb84CXA -jZbYbLOGhFioHCyiqfJwFbR7Abhsoo1NuEAtibJpFUm0oHym/Tjc4Xwht7cf52+8 -USfC918mFzmbPDOuIpkcHjGzXFztgDiMlX7iDrMvX2QOLzhp+g/I/pyAhAcKH8Eo -vcKeYOoQIM7hpP0eTZxgCDdRw9SpodU0/rTL6UzA4iXMcqncspH0OjfT5gxj3cOo -ofhaPxsIoqllZA/V/x7CeykdNE5L5SYv3c0NBnTMe9kV4K8V0JHTyz7N3ipiWJHP -VObvgdrJyA9YYCpgorfE7a1rtmLPfr5evrTuKP+VMEInqvA0mAxzX/HsbtsA+bNn -g6c5WibjO/kDKgfZfHFrPlLPiSSBVn9ygEySdlBuXpb5c7wft/YV0FyVAikbhY3l -3jJYmQ7kBxrtoIH9jK6Ff8rw7qbyBg6fDPoC3gevNdmoVtk5vTcKQTxPKlCeXTtE -JYfKDvX0BDkV8Wdizit03Sp0StpeietlX5vYQDyefp+w5J3k2SrbkEczzGZzXHq/ -5pm36cC0N0rA8ZW7JOpkThjZIJ733Y5DwtzhWqdUubWiCMmC7HfGmpI0OdV6QF8p -kCKXIsJ90Uiep0lEDNQZg4Y96kuUiEYEGBECAAYFAj0kfNoACgkQi9gubzC5S1xO -uACdELzJCBgMJVZ9siHwn48X2rXdQnIAn0yagIZfaIS0CfCamwcYeMfKcQQV -=GeL3 ------END PGP PUBLIC KEY BLOCK----- diff --git a/t/00-signature.t b/t/00-signature.t index 1cf917c..50a7346 100755 --- a/t/00-signature.t +++ b/t/00-signature.t @@ -1,17 +1,23 @@ #!/usr/bin/perl + use strict; print "1..1\n"; -if (!-s 'SIGNATURE') { +if (!$ENV{TEST_SIGNATURE}) { + print "ok 1 # skip Set the environment variable", + " TEST_SIGNATURE to enable this test\n"; +} +elsif (!-s 'SIGNATURE') { print "ok 1 # skip No signature file found\n"; } elsif (!eval { require Module::Signature; 1 }) { print "ok 1 # skip ", - "Next time around, consider install Module::Signature, ", - "so you can verify the integrity of this distribution.\n"; + "Next time around, consider install Module::Signature, ", + "so you can verify the integrity of this distribution.\n"; } -elsif (!eval { require Socket; Socket::inet_aton('pgp.mit.edu') }) { - print "ok 1 # skip Cannot connect to the keyserver\n"; +elsif (!eval { require Socket; Socket::inet_aton('pool.sks-keyservers.net') }) { + print "ok 1 # skip ", + "Cannot connect to the keyserver\n"; } else { (Module::Signature::verify() == Module::Signature::SIGNATURE_OK()) diff --git a/t/01-basic.t b/t/01-basic.t index c2a8403..efed735 100755 --- a/t/01-basic.t +++ b/t/01-basic.t @@ -1,20 +1,19 @@ #! /usr/bin/perl -w # Basic test suite -# -# Copyright (c) 2003-2007 imacat. -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . + +# Copyright (c) 2003-2021 imacat. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. use 5.006; use strict; @@ -26,7 +25,7 @@ use FindBin; use File::Spec::Functions qw(catdir updir); use File::Spec qw(); use lib $FindBin::Bin; -use vars qw($chklinks $start); +our ($chklinks, $start); $chklinks = catdir($FindBin::Bin, updir, "blib", "script", "chklinks"); $start = catdir($FindBin::Bin, "htdocs", "dir01", "start.html"); @@ -88,16 +87,16 @@ s/^.*test02.html [^\n]*\n//m; ok($_, qr/test3\.css /); s/^.*test3.css [^\n]*\n//m; # 17 -ok($_, qr/^http:\/\/www\.yahoo\.com\/nonexistent /m); -s/^http:\/\/www\.yahoo\.com\/nonexistent [^\n]*\n//m; -# 18 -ok($_, qr/^http:\/\/www\.domain\.invalid\/ /m); -s/^http:\/\/www\.domain\.invalid\/ [^\n]*\n//m; -# 19 -ok($_, qr/^ftp:\/\/ftp\.cpan\.org\/nonexistent /m); -s/^ftp:\/\/ftp\.cpan\.org\/nonexistent [^\n]*\n//m; -# 20 ok($_, qr/^ftp:\/\/ftp\.domain\.invalid\/ /m); s/^ftp:\/\/ftp\.domain\.invalid\/ [^\n]*\n//m; +# 18 +ok($_, qr/^ftp:\/\/ftp\.gnu\.org\/nonexistent /m); +s/^ftp:\/\/ftp\.gnu\.org\/nonexistent [^\n]*\n//m; +# 19 +ok($_, qr/^http:\/\/info\.cern\.ch\/nonexistent /m); +s/^http:\/\/info\.cern\.ch\/nonexistent [^\n]*\n//m; +# 20 +ok($_, qr/^http:\/\/www\.domain\.invalid\/ /m); +s/^http:\/\/www\.domain\.invalid\/ [^\n]*\n//m; # 21 ok($_, ""); diff --git a/t/htdocs/dir01/start.html b/t/htdocs/dir01/start.html index 06ebba4..6777a0b 100644 --- a/t/htdocs/dir01/start.html +++ b/t/htdocs/dir01/start.html @@ -1,17 +1,14 @@ - - - + - - + + Test Start

Test Start

-

閫欐槸涓闋佹脯瑭︾恫闋併

+

閫欐槸涓闋佹脯瑭︾恫闋併