4 ms·
This works well, but the web interface seems like an unnecessary layer on top of what could just be a terminal based tool. I'm trying to resist the urge to fork
by tmerr 10y ago
This works well, but the web interface seems like an unnecessary layer on top of what could just be a terminal based tool. I'm trying to resist the urge to fork this, putting another project on my todo list I will never finish
- tomjakubowski 10y agoThe lines connecting each explanation to the relevant part of the command line could be tricky to squeeze into a terminal window. You'd could instead create an interface with a movable "cursor", which highlights a single "chunk" of the command line, and presents the explanation for that "chunk" beneath the entire command line string.
- LostCharacter 10y agoI have a little bash script I picked up somewhere that uses mankier.com to a similar effect: explain () { if [ "$#" -eq 0 ] then while read -p "Command: " cmd do curl -Gs "https://www.mankier.com/api/explain/?cols="$(tput cols) --data-urlencode "q=$cmd" done echo "Bye!" elif [ "$#" -eq 1 ] then curl -Gs "https://www.mankier.com/api/explain/?cols="$(tput cols) --data-urlencode "q=$1" else echo "Usage" echo "explain interactive mode." echo "explain 'cmd -o | ...' one quoted command to explain it." fi }