
# cmarkfind

cmarkfind is a personal search engine for the Markdown web. It keeps the pages of the sites you read in one SQLite3 file and searches them locally through an index it builds from them; nothing is sent anywhere by a search. It fills the file from a site's table of contents (`/.well-known/toc.opml`), from a folder on disk or over the web, using [markdownweb](https://github.com/rsdoiel/markdownweb). [cmarkbrowser](https://github.com/rsdoiel/cmarkbrowser) searches the same file.

~~~shell
cmarkfind fill https://rsdoiel.github.io
cmarkfind fill ~/Sites/example.org
cmarkfind search oberon compiler
cmarkfind stats
~~~

A big site can be read a few pages at a time with `fill -batch 25 -every 1h -until-done`. Each site is an index set with an index of its own: `search` reads every set, `search-set NAME` reads one, and `set ignore NAME` leaves a near-duplicate copy out of a lookup. A folder of notes with no outline is read with `fill -name NAME FOLDER` and searched like any site. `exclude` keeps an address prefix out of the corpus; `forget` deletes a site's pages. `pin` puts a page first among the matches and `tag` gives it your own words; `search -pinned` and `search -tag` find them again. A site can publish its own index (`indexer discover SITE` finds it, `indexer add SITE` keeps a mirror that searches offline, `indexer add -reference SITE` keeps only the manifest), and `cmarkfind server` offers the corpus as a search service on this machine. `cmarkfind -help` is the manual; `cmarkfind help index` lists the topics (one for each verb, and the query syntax, the corpus and the exit codes); `cmarkfind help TOPIC` shows one.

The corpus is `cmarkfind/corpus.db` in your user data directory, or the file named by `-db` or `CMARKFIND_DB`.

### Authors

- Doiel, R. S.

## Related resources

- [Getting Help, Reporting bugs](https://github.com/rsdoiel/cmarkfind/issues)
- [LICENSE](https://www.gnu.org/licenses/agpl-3.0.txt)
- [Installation](INSTALL.md)
- [Manual](cmarkfind.1.md)
- Manual pages, one for each verb and topic:
  - [cmarkfind-fill(7)](cmarkfind-fill.7.md)
  - [cmarkfind-search(7)](cmarkfind-search.7.md)
  - [cmarkfind-search-set(7)](cmarkfind-search-set.7.md)
  - [cmarkfind-set(7)](cmarkfind-set.7.md)
  - [cmarkfind-indexer(7)](cmarkfind-indexer.7.md)
  - [cmarkfind-server(7)](cmarkfind-server.7.md)
  - [cmarkfind-stats(7)](cmarkfind-stats.7.md)
  - [cmarkfind-forget(7)](cmarkfind-forget.7.md)
  - [cmarkfind-exclude(7)](cmarkfind-exclude.7.md)
  - [cmarkfind-unexclude(7)](cmarkfind-unexclude.7.md)
  - [cmarkfind-pin(7)](cmarkfind-pin.7.md)
  - [cmarkfind-unpin(7)](cmarkfind-unpin.7.md)
  - [cmarkfind-tag(7)](cmarkfind-tag.7.md)
  - [cmarkfind-untag(7)](cmarkfind-untag.7.md)
  - [cmarkfind-verbs(7)](cmarkfind-verbs.7.md)
  - [cmarkfind-completion(7)](cmarkfind-completion.7.md)
  - [cmarkfind-query(7)](cmarkfind-query.7.md)
  - [cmarkfind-corpus(7)](cmarkfind-corpus.7.md)
  - [cmarkfind-exit-status(7)](cmarkfind-exit-status.7.md)
- [Change log](CHANGES.md)
- [About](about.md)
