diff options
Diffstat (limited to 'src/catalogue.lil')
-rw-r--r-- | src/catalogue.lil | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/catalogue.lil b/src/catalogue.lil index 4c719e2..3ca4b8f 100644 --- a/src/catalogue.lil +++ b/src/catalogue.lil @@ -14,8 +14,13 @@ on entry d t do # where d is a table representing a new row to be added to t, an existing table date_fmt_string:"date +%Y-%m-%d | tr -d '\n'" wget_fmt_string:"wget -qO- " , d.url , " | grep -o \"<title>[^<]*\" | sed -e 's/<[^>]*>//g' | tr -d '\n'" + wget_res:shell[wget_fmt_string].exit + # if wget_res.exit = -1 do + # exit["\n wget failed\n"] + # else + # t:insert title:(wget_res.out) reference:(d.url) created_date:(shell[date_fmt_string].out) into t + # end t:insert title:(shell[wget_fmt_string].out) reference:(d.url) created_date:(shell[date_fmt_string].out) into t - # TODO protect against wget fails end if args[2] do |