Code Monkey home page Code Monkey logo

bookertrans's Introduction

BookerTrans

用于 iBooker/ApacheCN 翻译项目的 HTML 谷歌翻译工具

安装

通过pip(推荐):

pip install BookerTrans

从源码安装:

pip install git+https://github.com/apachecn/BookerTrans

部分 API 依赖 Selenium 和 Chrome。请确保安装了 Chrome,并将其驱动放到PATH下。

使用说明

btrans [-h] [-v] [-H HOST] [-P PROXY] [-t TIMEOUT] [-w WAIT_SEC] 
       [-r RETRY] [-s SRC] [-d DST]
       site fname
       
-H HOST: 域名,默认为 translate.google.com
-P PROXY: 代理,格式为 \d+\.\d+\.\d+\.\d+:\d+,默认为空
-t TIMEOUT: 超时时间,以秒为单位,默认为 8
-w WAIT_SEC: 两次翻译之间的延迟(以秒为单位),默认为 0.5
-r RETRY: 重试次数,默认为 10
-s SRC: 源语言,默认为 auto
-d DST: 目标语言,默认为 zh-CN
site: API 名称,可选项为 {google,google_selenium,baidu,sogou,youdao}
fname: HTML 文件名称,或者文件所在的目录名称

协议

本项目基于 SATA 协议发布。

您有义务为此开源项目点赞,并考虑额外给予作者适当的奖励。

赞助我们

另见

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.