danger/u/
This thread is permanently archived
Dangeru through the terminal

| Hey I'm currently learning C and one of my (future) goals would be create some sort of ncurses irssi-like client for this textboard.
Any pointers for a noob?


| Canibalising the internals of Lynx and/or w3m text browsers could be a start. I am very mediocre as a C programmer but that is where Id start.


| I disagree with >>74811
i'd just scrape the site using a simple html parser, no need for the complexity.

##Admin:prefetcher##

| https://github.com/dangeru/awoo-API


| "don't @ me about programming unless you tweet from the command line"


| >>76617 now that is cyberpunk


| this is a test using danger/u/ through terminal by using the text based browser "lynx"
so if you can read this probably other terminal based browsers may also work here ;-)


| https://en.wikipedia.org/wiki/Text-based_web_browser
as you could see lynx worked like a charm. You have to handle Key-Shorcuts and cookie warnings :-)


| >>76550
Anon said he is learning C and has thought about a way to make the process fun and attractive and transforming study into enjoyful play. There is no best way to learn than looking at something that works and understanding how and why it does so and then trying to mimic it. A text scrapper does nothing towards that goal. Slight problem would be that lynx or w3m code is quite robust and complicated and stable and daunting. It could be scary swimming in industrial grade code.


|


| C isn't a great choice for something like this. The boilerplate of config/option parsing and string-handling and ncurses for something that's solely text-wrangling isn't worth it, and you'll run out of steam


| >>77652
so what language would be a good fit for this idea?
I'll still continue learning C anyways.


| >>79352
There's Python, which can parse JSON easily (assuming you plan on using the API and not stupidly parsing the site's HTML file). Really though, as long as it can parse JSON, you'll better off using the API.


| >>79360
I'll get around to python eventually, thanks for the info!


| In case you're interested I already made a python wrapper for the API with my client https://github.com/sugoiuguu/awoo-cli


| >>74797 scrape the site and use sed to format the text. All can be done in one command

Total number of posts: 16, last modified on: Sat Jan 1 00:00:00 1514142276

This thread is permanently archived