Git Product home page Git Product logo

ttslanguage's Introduction

TTSLanguage

Text To Speech commandline executable for macOS. It can detect sentence language and read it using proper voice.

example:

$ TTSLanguage "Hello my Friend! Bonjour camarade! Cześć kolego."

It can also read lang attributes from html. example:

$ TTSLanguage "<span lang=\"en-US\">In Paris the name of the city is pronounced</span><span lang=\"fr-FR\">Paris</span>"

It's created for an answer to AskDifferent question: https://apple.stackexchange.com/q/434992/74657

Installation

Compiled

Compiled sources can be found in Playground/Testing.playground/Resources/TTSLanguage.zip

In order to use it in different places remember to store TTSLanguageLib.framework in the same dir as TTSLanguage executable.

Building

Everything could be build using Xcode or with:

$ xcodebuild -workspace TTSLanguage.xcodeproj/project.xcworkspace -scheme TTSLanguage archive -archivePath $PWD/build/TTSLanguage.xcarchive && open build/TTSLanguage.xcarchive/Products/usr/local/bin/ 

macOS Service

It can be run as a macOS service.

  • In Automator.app create Service with text input.
  • Add "Run shell Sscript" block
  • Change input type to stdin
  • Place this script inside:
myVar=$(</dev/stdin)
$PATH_TO_TTSLanguage_EXECUTABLE "$myVar"

NOTE: $PATH_TO_TTSLanguage_EXECUTABLE is the place on disk where you stored TTSLanguage executable.

Shortcuts

Shortcuts file is in Playground/Testing.playground/Resources/TTSLangShort.shortcut. Please adjust the location of the TTSLanguage executable.

Dependencies

ttslanguage's People

Contributors

slozo avatar

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.