SkillAgentSearch skills...

Golucy

Go bindings for the Apache Lucy full text search library. The Apache Lucy search engine library provides full-text search for dynamic programming languages. It is a "loose C" port of the Apache Lucene™ search engine library for Java.

Install / Use

/learn @ps0uth/Golucy
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

golucy

golucy

Go bindings for Apache Lucy. The Apache Lucy search engine library provides full-text search for dynamic programming languages. It is a "loose C" port of the Apache Lucene™ search engine library for Java.

Dependencies

Go

Duh.

Lucy

Works as of commit e19687f9a6b0158308ac7bcafc663296635b107a.

$ export BUILD_DIR=$HOME/build
$ export LUCY_HOME=$HOME/.local/lucy
$ cd $BUILD_DIR
$ git clone https://git-wip-us.apache.org/repos/asf/lucy.git
$ cd $BUILD_DIR/lucy/c
$ git checkout e19687f9a6b0158308ac7bcafc663296635b107a
$ ./configure --prefix=$LUCY_HOME
$ make && make test && make install
$ ./install.sh --prefix $LUCY_HOME
$ cd $BUILD_DIR/lucy/clownfish/runtime/c
$ ./configure --prefix=$LUCY_HOME
$ make && make test && make install
$ ./install.sh --prefix $LUCY_HOME

Configuration

Add the following to your .profile or .zshrc or similar (you will also need to have your GOHOME and/or GOPATH set).

export LUCY_HOME=$HOME/.local/lucy
export CGO_LDFLAGS="-L$LUCY_HOME/lib -llucy -lcfish ${CGO_LDFLAGS}"
export CGO_CFLAGS="-I$LUCY_HOME/include ${CGO_CFLAGS}"
export LD_LIBRARY_PATH=$LUCY_HOME/lib:$LD_LIBRARY_PATH

Installation

Provided you have the dependencies in order add this:

import (
  golucy "github.com/philipsoutham/golucy/v0.0.1"
)

then do:

$ go get 

Example

See this example, inspired by this one in C. If you're running docker you can see it in action like so.

$ docker pull psoutham/golucy
$ docker run psoutham/golucy

Details on the docker image can be found here.

View on GitHub
GitHub Stars47
CategoryDevelopment
Updated2y ago
Forks2

Languages

Go

Security Score

75/100

Audited on May 10, 2023

No findings