master
Bel LaPointe 2022-02-01 14:16:44 -07:00
parent 165f85a443
commit 9b05003329
2 changed files with 4 additions and 7 deletions

View File

@ -24,7 +24,7 @@ config() {
}
log() {
echo "$(date +%H:%M:%S)> $*" >&2
echo "$(echo "$(date +%H:%M:%S)> $*" | tr '\n' ' ')" >&2
}
ids() {
@ -45,7 +45,7 @@ _crawl() {
local json="$(notea get "$id")"
local content="$(echo "$json" | jq -r .content)"
if ! is_crawlable "$content"; then
log "$content is not crawlable"
log "not crawlable: '${content:0:20}'..."
return 0
fi
local crawlable_source="$(extract_crawlable_source "$content")"
@ -80,9 +80,6 @@ crawl_with() {
log " $PID/$ID ($TITLE): ${#CONTENT}"
notea put
done
log not impl crawl with
return 1
}
is_crawlable() {
@ -93,7 +90,7 @@ is_crawlable() {
}
rewrite() {
log not impl rewrite
log not impl rewrite, change images
return 1
}

View File

@ -47,7 +47,7 @@ notea() (
"pid": '"$(echo "$PID" | jq -R)"',
"pinned": 0,
"shared": 0,
"title": '"$(echo "$TITLE" | jq -R)"'
"title": '"$(echo "$TITLE [generated]" | jq -R)"'
}' | jq -c .)"
echo "$request" | ncurl \
-X POST \