Skip to content

The Golang client library for Fist (Full Index Search Text) search engine

License

Notifications You must be signed in to change notification settings

sonirico/go-fist

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status Coverage Status Go Report Card GoDoc contributions welcome dependencies: none

Golang client to interact with Fist, a minimalist full-text index search server with a focus on keeping things simple

Install

go get -u github.com/sonirico/go-fist

Examples

import fistClient "github.com/sonirico/go-fist"

// ...

client, err := fistClient.NewFistClient("localhost", "5575")
if err != nil {
    fmt.Println("Connection Error! Is Fist up and running?")
    return
}
// Obtain server version
version, _ := client.Version()
fmt.Println("Server version is " + version)
// Index some data
client.Index("articles", "a an the")
client.Index("TODO", "wash the car")
client.Index("TODO", "walk the dog")
client.Index("podcasts", "DSE - Daily software engineering")
// Search for "the" keyword
documents := client.Search("the")
fmt.Println(documents) // ["articles", "TODO"]
// Not needing articles?
client.Delete("the")
documents = client.Search("the")
fmt.Println(documents) // []

More detailed examples can be found under the ./examples subpackage

Release strategy

Every time a new version for the server shall be released, so will the client so as to keep a direct and easy to follow client/server version mirroring

License

Released under the terms of the MIT license. Refer to LICENSE for more details.

About

The Golang client library for Fist (Full Index Search Text) search engine

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published