No creo que curl tenga un procesador HTML incorporado. Sin embargo:
lynx --dump <URL>
hace el truco.
Si aún desea usar curl, puede usar html2text
(disponible en Ubuntu).
Puedes instalar html2text
(un convertidor avanzado de HTML a texto) y el uso es sencillo:
$ html2text http://example.com/
$ cat file.html | html2text -o file.txt
Instalar por:
- Linux:
apt-get install html2text
- OS X:
brew install html2text
Ejemplo con curl
:
$ curl -sL google.com | html2text
Search Images Maps Play YouTube News Gmail Drive More ?
Web History | Settings | Sign in
A better way to browse the web
Get Google Chrome
Advanced search Language tools
[Google Search][I'm Feeling Lucky]
Advertising Programmes Business Solutions+GoogleAbout GoogleGoogle.com
? 2016 - Privacy - Terms