- setting
SEARCH_ALL_VISIBLE_TOOTS=truein your instance config will let users search all non-private posts, not just the ones they've interacted with. - prefixing a search query with
🔍will use ES simple query string syntax instead of Mastodon's weird broken subset of it, which will let you use "double quotes" for literal strings including white space, + to force a term to be included, or - to force a term to be excluded. - prefixing a search query with
🔎will use ES regular query string syntax which is like simple query syntax, except:- syntax errors will cause the search to fail, so if you don't get anything back, that's why.
- you can specify individual fields to match on. if you don't specify a field for a given search term, it does a normal full-text search for
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // NOTE: We must export or import at least one thing so we are not in | |
| // the "global" scope, but in a module scope which is re-declarable. | |
| // | |
| // The error from tsserver is: 2451: Cannot redeclare block-scoped | |
| // variable 'self'. | |
| // | |
| // Even tho this is not really a module and cannot be: ServiceWorkers | |
| // cannot be modules. | |
| export type Version = number |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package util | |
| import ( | |
| "errors" | |
| "fmt" | |
| "net" | |
| ) | |
| // useful links: | |
| // https://stackoverflow.com/questions/27410764/dial-with-a-specific-address-interface-golang |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "database/sql" | |
| "github.com/mattn/go-sqlite3" | |
| "log" | |
| "os" | |
| ) | |
| func runQuery(db *sql.DB, query string) { |