@snomiao/say
TypeScript icon, indicating that this package has built-in type declarations

0.1.35 • Public • Published

@snomiao/say

A cli wrapper for say

Usage Examples

npx -y -- @snomiao/say --list
# Microsoft David Desktop
# Microsoft Zira Desktop

npx -y -- @snomiao/say hello, world
npx -y -- @snomiao/say --voice "Microsoft David Desktop" --speed 0.5 hello, world
npx -y -- @snomiao/say --voice "Microsoft Zira Desktop" --speed 1.5 hello, world
npx -y -- @snomiao/say --voice "Microsoft Zira Desktop" --speed 1.5 --output ./hello-world.mp3 hello, world

# or

npm i -g @snomiao/say

say --list
say --voice "Microsoft David Desktop" --speed 0.5 hello, world
say --voice "Microsoft Zira Desktop" --speed 1.5 hello, world
say --voice "Microsoft Zira Desktop" --speed 1.5 --output ./hello-world.mp3 hello, world

# you can kill the process if you need to stop saying

Import as Library

import { speak } from "@snomiao/say";
await speak("test passed", undefined, 2);

Declares

export declare const speak: (
  text: string,
  voice?: string | undefined,
  speed?: number | undefined,
) => Promise<void>;
export declare const stop: () => Promise<void>;
export declare const getInstalledVoices: () => Promise<string[]>;
export declare const exportFile: (
  text: string,
  voice?: string | undefined,
  speed?: number | undefined,
  filePath?: string | undefined,
) => Promise<void>;

Author & License

Author: snomiao snomiao@gmail.com LICENSE: GPLv3

ref

Readme

Keywords

Package Sidebar

Install

npm i @snomiao/say

Weekly Downloads

0

Version

0.1.35

License

GPLv3

Unpacked Size

40.7 kB

Total Files

8

Last publish

Collaborators

  • snomiao