Skip to content
Alfred 3 workflow - translate with google api
JavaScript
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
media add jetbrains support Aug 6, 2019
.gitignore update .gitignore Jun 11, 2019
README.md add jetbrains support Aug 6, 2019
icon.png first commit Nov 15, 2017
index.js polish Aug 2, 2019
info.plist fixed #26 Aug 1, 2019
languages.js update media Jun 10, 2019
license first commit Nov 15, 2017
package.json update version Aug 1, 2019
token.js fixed #26 Aug 1, 2019
translate.js polish Aug 2, 2019
tts.js fixed #26 Aug 1, 2019
tts.png update tts icon Dec 6, 2018

README.md

alfred-google-translate

NPM

JetBrains' support

jetbrain

Install

Requires Node.js 4+ and the Alfred Powerpack.

  • install with npm install -g alfred-google-translate
  • or download workflow

Changelog

Usage

Before using this workflow, You must config the language pair. see alfred-language-configuration, (The Language Auto Detected btw, #36)

Alfred workflow Keyword tr.

the shown items explain:

The first item is input word or sentence (webster phonetic if avaliable).

The second item is translation of input (webster phonetic if avaliable).

The rest of items are Definitions and Translations of input.

at the first and second item You can:

  • press enter to read the item.
  • press cmd+C to copy the item.
  • press shift open the translate website.
  • press cmd+L to see the full content.

if You input wrong word, the workflow will correct your input, and You can press enter to see.

Environment Variables

name default value description
domain https://translate.google.com if you cannot access the default domain, you can config this.
大陆访问不了默认域名,所以如果使用2.x版本需要将这个变量设置为https://translate.google.cn. 或者还是使用1.x版本
voice remote avaliable values:
remote: fetch voice from google,
local: use macOS local voice (notice: maybe only works on English),
none: dont get voice
save_count 20 limit count of translate history, see alfred-translate-history.
0 means dont save translate history
environment variables config snapshot:

env-config.png

env.png

Hotkey

if you download the workflow, you may lost the hotkey, so you can manual config this.

hotkey config snapshot:

hotkey.png

hotkey-config.png

hotkey and largetype snapshot:

result

Snapshot

  • correct

    corrected.png

  • press enter to read,presscmd+C to copy

    general.png

  • press shift to open translate website

    quicklook.png

  • press cmd+L to show full content,like the gif in hotkey.

Related

License

MIT ©

You can’t perform that action at this time.