Welcome, Guest. Please login or register.
Did you miss your activation email?

Author Topic: [DE] html2text Ausgabe fehlerhaft?  (Read 1081 times)

Offline bluelupo

  • User
  • Posts: 2.068
    • BluelupoMe
[DE] html2text Ausgabe fehlerhaft?
« on: 2013/02/26, 14:49:58 »
Hallo zusammen,
z.zt. wurmt mich das Tool html2text ein bisschen. Irgendwie unterschlägt das Teil ein paar Informationen. Ich hole mir per wget die index.html der siduction Kernel und wandle dieses HTML-File danach in ein ASCII-File um. Nun werden bei ein paar Zeilen die Uhrzeiten nicht angezeigt, obwohl diese tatsächlich existieren (im Browser kontrolliert).

Ist das ein Bug oder kann man das anderweitig beheben?

Code: [Select]

$ wget -qnv -O - ftp://ftp.uni-stuttgart.de/siduction/base/pool/main/l/linux-siduction/ | html2text -width 132
****** Index von /siduction/base/pool/main/l/linux-siduction auf ftp.uni-stuttgart.de:21 ******
====================================================================================================================================
  2012 Jul 17        Datei       linux-headers-3.4-5.towo-siduction-686-pae_3.4-15_i386.deb  (4943494 Bytes)
  2012 Jul 17        Datei       linux-headers-3.4-5.towo-siduction-686_3.4-15_i386.deb  (4944612 Bytes)
  2012 Jul 17        Datei       linux-headers-3.4-5.towo-siduction-amd64_3.4-15_amd64.deb  (4951156 Bytes)
  2012 Aug 18        Datei       linux-headers-3.5-2.towo-siduction-686-pae_3.5-6_i386.deb  (5032944 Bytes)
  2012 Aug 18        Datei       linux-headers-3.5-2.towo-siduction-686_3.5-6_i386.deb  (5030238 Bytes)
  2012 Aug 18        Datei       linux-headers-3.5-2.towo-siduction-amd64_3.5-6_amd64.deb  (5037536 Bytes)
  2012 Aug 30 19:10  Datei       linux-headers-3.5-3.towo-siduction-686-pae_3.5-8_i386.deb  (5034374 Bytes)
  2012 Aug 30 19:10  Datei       linux-headers-3.5-3.towo-siduction-686_3.5-8_i386.deb  (5030256 Bytes)
  2012 Aug 30 19:10  Datei       linux-headers-3.5-3.towo-siduction-amd64_3.5-8_amd64.deb  (5038760 Bytes)
  2012 Sep 15 16:25  Datei       linux-headers-3.5-4.towo-siduction-686-pae_3.5-9_i386.deb  (5032726 Bytes)
  2012 Sep 15 16:25  Datei       linux-headers-3.5-4.towo-siduction-686_3.5-9_i386.deb  (5029956 Bytes)
  2012 Sep 15 16:20  Datei       linux-headers-3.5-4.towo-siduction-amd64_3.5-9_amd64.deb  (5038780 Bytes)
[...]

Offline michaa7

  • User
  • Posts: 2.300
Re: html2text Ausgabe fehlerhaft?
« Reply #1 on: 2013/02/26, 15:24:17 »
Quote from: "bluelupo"
...Ich hole mir per wget die index.html der siduction Kernel ...

versucht mal explizit die zu holen (das tust du ja nicht, du glaubst nur dass du das tust)
Quote
...Nun werden bei ein paar Zeilen die Uhrzeiten nicht angezeigt, obwohl diese tatsächlich existieren (im Browser kontrolliert).
...

Die uhrzeit steht garantiert nicht in irgendeinem statischen quelltext, wie könnte das auch sein? Und wie eine dynamisch erzeugte ausgabe (php, ein CMS, was weiß ich) deinen *ftp zugriff* verarbeitet ist mit nicht wirklich klar.

Vielleicht hast du schon gewonnen wenn du statt ftp per http (geht auch mit wget als option) auf die seite zugreifst, (vielleicht noch mit zusätzlich gefaktem user agent). Ist zumindest nen versuch wert.
Ok, you can't code, but you still might be able to write a bug report for Debian's sake

Offline bluelupo

  • User
  • Posts: 2.068
    • BluelupoMe
Re: html2text Ausgabe fehlerhaft?
« Reply #2 on: 2013/02/26, 16:04:48 »
Hi michaa7,
ich hab's gelöst, das liegt am Listung der ftp-Seite, denn das lehnt sich am ls-Kommando an. Das heißt bei älteren Dateien werden nur noch Jahr/Monat/Tag angezeigt im Zeitstempel.

Code: [Select]

$ wget -q -O - ftp://ftp.uni-stuttgart.de/siduction/base/pool/main/l/linux-siduction/ | html2text -width 132
****** Index von /siduction/base/pool/main/l/linux-siduction auf ftp.uni-stuttgart.de:21 ******
====================================================================================================================================
  2012 Jul 17        Datei       linux-headers-3.4-5.towo-siduction-686-pae_3.4-15_i386.deb  (4943494 Bytes)
  2012 Jul 17        Datei       linux-headers-3.4-5.towo-siduction-686_3.4-15_i386.deb  (4944612 Bytes)
  2012 Jul 17        Datei       linux-headers-3.4-5.towo-siduction-amd64_3.4-15_amd64.deb  (4951156 Bytes)
  2012 Aug 18        Datei       linux-headers-3.5-2.towo-siduction-686-pae_3.5-6_i386.deb  (5032944 Bytes)
  2012 Aug 18        Datei       linux-headers-3.5-2.towo-siduction-686_3.5-6_i386.deb  (5030238 Bytes)
  2012 Aug 18        Datei       linux-headers-3.5-2.towo-siduction-amd64_3.5-6_amd64.deb  (5037536 Bytes)
  2012 Aug 30 19:10  Datei       linux-headers-3.5-3.towo-siduction-686-pae_3.5-8_i386.deb  (5034374 Bytes)
  2012 Aug 30 19:10  Datei       linux-headers-3.5-3.towo-siduction-686_3.5-8_i386.deb  (5030256 Bytes)
  2012 Aug 30 19:10  Datei       linux-headers-3.5-3.towo-siduction-amd64_3.5-8_amd64.deb  (5038760 Bytes)
[...]


Beim Zugriff via http werden die Zeiten, warum auch immer, angezeigt.
Code: [Select]

wget -q -O - http://ftp.uni-stuttgart.de/siduction/base/pool/main/l/linux-siduction/ | html2text -width 132
[[DIR]] Parent_Directory                                                                  -
[[   ]] linux-headers-3.4-5.towo-siduction-686-pae_3.4-15_i386.deb   17-Jul-2012 11:00  4.7M
[[   ]] linux-headers-3.4-5.towo-siduction-686_3.4-15_i386.deb       17-Jul-2012 11:00  4.7M
[[   ]] linux-headers-3.4-5.towo-siduction-amd64_3.4-15_amd64.deb    17-Jul-2012 10:55  4.7M
[[   ]] linux-headers-3.5-2.towo-siduction-686-pae_3.5-6_i386.deb    18-Aug-2012 12:50  4.8M
[[   ]] linux-headers-3.5-2.towo-siduction-686_3.5-6_i386.deb        18-Aug-2012 12:50  4.8M
[[   ]] linux-headers-3.5-2.towo-siduction-amd64_3.5-6_amd64.deb     18-Aug-2012 12:50  4.8M
[[   ]] linux-headers-3.5-3.towo-siduction-686-pae_3.5-8_i386.deb    30-Aug-2012 21:10  4.8M
[[   ]] linux-headers-3.5-3.towo-siduction-686_3.5-8_i386.deb        30-Aug-2012 21:10  4.8M
[[   ]] linux-headers-3.5-3.towo-siduction-amd64_3.5-8_amd64.deb     30-Aug-2012 21:10  4.8M
[...]