diff options
author | default <nobody@localhost> | 2024-05-08 11:00:50 +0200 |
---|---|---|
committer | default <nobody@localhost> | 2024-05-08 11:00:50 +0200 |
commit | 52ba7f030ed50f22b7fbf437e83c9415ed0e91ed (patch) | |
tree | 83fa1f640cf4f4f9082074f499a31743ba46d134 /main.c | |
parent | dc74cac6c9c3f6e9edc848381422a1f124abac73 (diff) |
Renamed to content_search().
Diffstat (limited to 'main.c')
-rw-r--r-- | main.c | 21 |
1 files changed, 20 insertions, 1 deletions
@@ -380,7 +380,26 @@ int main(int argc, char *argv[]) int to; /* 'url' contains the regex */ - xs *r = search_by_content(&snac, tl, url, 10, &to); + xs *r = content_search(&snac, tl, url, 10, &to); + + int c = 0; + char *v; + + /* print results as standalone links */ + while (xs_list_next(r, &v, &c)) { + printf("%s/admin/p/%s\n", snac.actor, v); + } + + return 0; + } + + if (strcmp(cmd, "search2") == 0) { /** **/ + /* undocumented (for testing only) */ + xs *tl = timeline_simple_list(&snac, "public", 0, XS_ALL); + int to; + + /* 'url' contains the regex */ + xs *r = content_search(&snac, tl, url, 10, &to); int c = 0; char *v; |