Project

dickens

0.0
No commit activity in last 3 years
No release in over 3 years
For now you can gather all your dictionaries together and search through them getting pretty rails-style records back
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
 Dependencies

Development

>= 0
 Project Readme

#Dickens Dickens is made to work with great collections of StarDict Dictionaries - simple ruby wrapper around SDCV.

gem install dickens

SDCV installation

Linux

  sudo apt-get install sdcv

MacOS

In Mac OS it is possible to install SDCV using Ports:

  sudo port install sdcv

Dictionaries

Lots of dics may be found across the net. The starting point may be (here)[http://www.stardict.org/download.php]

Install dictionaries on Linux

  sudo tar -xvzf downlaoded.tar.gz -C /usr/share/stardict/dic

Install dictionaries on Mac OS

mkdir -p $HOME/.stardict/dic
sudo tar -xvjf downloaded.tar.bz2 -C $HOME/.stardict/dic

API methods

List

After everything is installed you can list the dictionaries:

  Dickens::StarDict.list

Find

You can lookup desired definition through all dics at once:

  Dickens::StarDict.find("Dickens")

Where

Define dictionaries to lookup only inside those dics:

  list=Dickens::StarDict.list
  Dickens::StarDict.where("Dickens", [list[1], list[3]])

Configuration

Change the path to executable:

  Dickens::StarDict.executable = "./lib/my_sdcv"

Control your options

  Dickens::StarDict.config :use_dict => false,
                           :utf8_input => true,
                           :utf8_output => true,
                           :non_interactive => true,
                           :data_dir=>false