info:linkchecker

Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Prochaine révision
Révision précédente
info:linkchecker [2021/01/15 05:39] – créée radeffinfo:linkchecker [2025/11/06 09:38] (Version actuelle) radeff
Ligne 5: Ligne 5:
 LinkChecker is a free, GPL licensed URL validator. LinkChecker is a free, GPL licensed URL validator.
  
-http://wummel.github.io/linkchecker/+https://github.com/wummel/linkchecker
  
-**Exemple** +===== Exemple ===== 
-   linkchecker https://radeff.red/blog --output=html > ~/checklinks.html +==== rendu html ==== 
-    +<code bash> 
-   -oTYPE[/ENCODING], --output=TYPE[/ENCODING]+linkchecker https://radeff.red/blog --output=html > ~/checklinks.html 
 +</code> 
 +==== rendu csv ==== 
 +<code bash> 
 +   linkchecker https://radeff.red/blog --output=csv > ~/checklinks.csv 
 +</code> 
 +==== autres options ==== 
 +<code bash>    
 +   -o TYPE[/ENCODING], --output=TYPE[/ENCODING]
     Specify output type as text, html, sql, csv, gml, dot, xml, sitemap, none or blacklist. Default type is text. The various output types are documented below.     Specify output type as text, html, sql, csv, gml, dot, xml, sitemap, none or blacklist. Default type is text. The various output types are documented below.
     The ENCODING specifies the output encoding, the default is that of your locale. Valid encodings are listed at http://docs.python.org/library/codecs.html#standard-encodings.      The ENCODING specifies the output encoding, the default is that of your locale. Valid encodings are listed at http://docs.python.org/library/codecs.html#standard-encodings. 
          
     use --check-extern to check extern URLs.     use --check-extern to check extern URLs.
 +</code>
            
-     +<note warning>ATTENTION! récursion</note> 
-**Doc**+Par défaut, linkchecker lance une récursion infinie... Si votre site est gros, cela peut vite devenir une sacrée usine à gaz et méchamment charger votre serveur: 
 + 
 +<code bash> 
 +-rNUMBER, --recursion-level=NUMBER 
 +    Check recursively all links up to given depth. A negative depth will enable infinite recursion. Default depth is infinite.  
 +</code> 
 + 
 +==== Pour limiter à un seul namespace (liens internes) ==== 
 + 
 +=== solution 1 === 
 +on va ici vérifier uniquement les liens de type www.monsite.ch/monrepertoire 
 + 
 +<code bash> 
 +linkchecker \ 
 +  --check-extern \ 
 +  --ignore-url="^https://www\.monsite\.ch/(?!monrepertoire/)"
 +  --ignore-url="^https://www\.monsite\.ch/monrepertoire/#"
 +  --no-status \ 
 +  --verbose \ 
 +  https://www.monsite.ch/monrepertoire/ 
 +</code> 
 +=== solution 2 === 
 +utiliser l'option **-r1** :
  
-http://linkchecker.sourceforge.net/man1/linkchecker.1.html+   linkchecker -r1 https://radeff.red/recettes/restaurants --output=html > ~/checklinks.html
  
  • info/linkchecker.1610685556.txt.gz
  • Dernière modification : 2021/01/15 05:39
  • de radeff