23 lines
428 B
Bash
Executable File
23 lines
428 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
set +e
|
|
|
|
printf "%s" "Enter URL: "
|
|
read URL
|
|
|
|
articles=$(curl -s "$URL/articles.txt")
|
|
|
|
# list=''
|
|
# while IFS= read article; do
|
|
# list+="$article "
|
|
# done < <(printf '%s' "$articles")
|
|
|
|
while :
|
|
do
|
|
article=$(./tools/widgets/list_selector.py --desc="Select an article:" --result="line" -- $articles)
|
|
if [ -z "$article" ]; then
|
|
break
|
|
fi
|
|
curl -s "$URL/markdown/$article.md" | pager
|
|
done
|