Giter Club home page Giter Club logo

pyshanb's Introduction

PyShanb:命令行下的扇贝词典

Build Pypi version Pypi downloads

基于 扇贝网 API v0.8 开发的一个命令行下的查词工具。

文档

http://pyshanb.readthedocs.org/

功能

  • 自动登录扇贝网(需要配置用户名及密码);
  • 显示单词中文释义;
  • 显示单词英文释义(可选,默认禁用);
  • 自动发音(Windows only)(可选,默认禁用);
  • 自动添加单词到扇贝网词库(当天待背单词列表)(可选,默认禁用);
  • 询问是否添加单词到扇贝网词库(可选,默认启用);
  • 显示例句(显示用户在扇贝网添加的例句)(可选,默认禁用);
  • 配置文件(配置用户名、密码及其他功能项);
  • 从爱词霸网获取单词信息(可选,默认禁用);
  • 通过命令行参数指定配置文件、用户名及密码等;
  • 登录后显示用户昵称;
  • 添加单词例句(可选,默认启用);
  • 高亮单词及错误信息。
  • 插件功能

安装使用

  1. pip install pyshanb
  2. 命令行下执行:shanbay -u username -p password(Tips:使用过程中输入 q 即可退出程序)。

命令行参数

>shanbay --hlep
usage: shanbay.py [-h] [-V] [-s SETTINGS] [-u USERNAME] [-p PASSWORD]
                  [-e | -E] [-i | -I] [-a | -A]
                  [--color {black,white,red,green,yellow,blue,magenta,cyan,gray}]
                  [--plugin {youdao}] [--example | --disable-example]
                  [--english | --disable-english]

An command line tool for shanbay.com.

optional arguments:
  -h, --help            show this help message and exit
  -V, --version         show program's version number and exit
  -s SETTINGS, --settings SETTINGS
                        the settings file of the application
  -u USERNAME, --username USERNAME
                        the account username of shanbay.com
  -p PASSWORD, --password PASSWORD
                        the account password of shanbay.com
  -e, --add-example     enable "Add example" feature
  -E, --disable-add-example
                        disable "Add example" feature
  -i, --iciba           enable "Get data from iciba.com" feature
  -I, --disable-iciba   disable "Get data from iciba.com" feature
  -a, --auto-play       enable "Auto play audio" feature
  -A, --disable-auto-play
                        disable "Auto play audio" feature
  --color {black,white,red,green,yellow,blue,magenta,cyan,gray}
                        colorize keyword (default: green)
  --plugin {youdao}     enable plugin
  --example, --enable-example
                        enable examples
  --disable-example     disable examples
  --english             enable english definition
  --disable-english     disable english definition

License

Licensed under the MIT License.

图标版权归 扇贝网 所有.

pyshanb's People

Contributors

mozillazg avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

pyshanb's Issues

可以添加例句

  • 询问是否添加例句
  • 例句及解释不能为空
  • 配置文件控制启用/禁用该功能
  • 命令行选项控制是否启用/禁用该功能
  • 命令行选项优先级高于配置文件选项

更加友好的命令行方式

既支持「交互」方式(现有的),也支持「命令」方式。
「命令」的输出结果,在 Linux 下可以方便的用管道传给其他程序。
好像一般支持交互的命令行程序,都会用 -i 参数表示以交互方式运行。

兼容性更新

请问下作者,这个工具是不是停止更新、放弃维护了?
试用了一下提示 Login failed!
看多最近的commit是三年前,应该是使用的扇贝api已经过期了?
有计划重启这个项目吗?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.