Gem [分享] dict_cache 帮助你在 terminal 里查询单词和浏览查询记录

small_fish__ · 2016年03月04日 · 最后由 lingceng 回复于 2016年03月07日 · 2314 次阅读

背景:

ruby 开发对英文单词量比较高,像我这种半吊子英文水平,使用英汉字典翻译的时候较多。

前段时间看到 @lingceng 写的 bing_dictionary ,试用结果非常满意,速度快而且翻译比较准确。最近开始背诵单词,所以想将每天查询记录收集起来,以备每晚巩固之用,故写了 dict_cache

安装

gem install dict_cache

如何使用

1. 翻译单词(用到 bing_dictionary)

dict apple

translate_word.png

2. 查询每日记录,默认是当天

dict_cache date:2016-03-04
dict_cache // today is default

list_words.png

3. dict_cache clear 清空所有缓存记录

4. dict_cache --help/-h 帮助

欢迎大家使用,有任何问题和想法,欢迎提 issue 和 pr .

貌似在 rails 服务器启动的时候,无法使用!

#1 楼 @shin 如果目录下有 Gemfile 文件,会失败,需要切换到一个没有 Gemfile 的目录

我下载过 mdx 格式的词典,然后分析格式,将每个单词的解释和发音 mp3 保存到了本地 sqlite。有了它不需要联网就可以查单词。楼主要不要?

:plus1: 因为你的文章,项目多了些 star 😄

需要 登录 后方可回复, 如果你还没有账号请 注册新账号