GithubHelp home page GithubHelp logo

isabella232 / snips-action-timer Goto Github PK

View Code? Open in Web Editor NEW

This project forked from snipsco/snips-action-timer

0.0 0.0 0.0 907 KB

Snips action code for the Timer app

License: MIT License

Shell 0.28% JavaScript 0.24% TypeScript 99.48%

snips-action-timer's Introduction

snips-action-timer

Snips action code for the Timer app

Build Status

Setup

# Install the dependencies, builds the action and creates the config.ini file.
sh setup.sh

Don't forget to edit the config.ini file.

An assistant containing the intents listed below must be installed on your system. Deploy it following these instructions.

Run

  • Dev mode:
# Dev mode watches for file changes and restarts the action.
npm run dev
  • Prod mode:
# 1) Lint, transpile and test.
npm start
# 2) Run the action.
npm run launch

Test & Demo cases

This app only supports french ๐Ÿ‡ซ๐Ÿ‡ท and english ๐Ÿ‡ฌ๐Ÿ‡ง.

SetTimer

Set a timer optionally with a name

Set a timer with the given time

Hey Snips, create a timer for 25 minutes

Set a timer with the given time and name

Hey Snips, set the homework timer for 30 minutes

GetRemainingTime

Get the remaining time of a timer, optionally for a specific timer name or duration

Get the remaining time of the current timers

Hey Snips, I want an update on my timer

Get the remaining time of the timer with the given duration

Hey Snips, when will be my 7 minute timer finished?

Get the remaining time of the timer with the given name

Hey Snips, when is the pizza timer done?

PauseTimer

Pause a timer, optionally for a specific timer name or duration

Pause all the current timers

Hey Snips, can you pause all my timers

Pause the timer with the given duration

Hey Snips, pause my 5 minute timer please

Pause the timer with the given name

Hey Snips, I would like to pause my yoga timer

ResumeTimer

Resume a timer, optionally for a specific timer name or duration

Resume all the current timers

Hey Snips, resume all of my active timers

Resume the timer with the given duration

Hey Snips, I'd like you to resume my 1 hour timer

Resume the timer with the given name and duration

Hey Snips, start again my 10 minute pasta timer

CancelTimer

Cancel a timer, optionally for a specific timer name or duration

Cancel all the timers with the given name

Hey Snips, please cancel all my yoga workout timers

Cancel the timer with the given duration

Hey Snips, I'd like you to cancel my 4 minute timer

Cancel the timer with the given name and duration

Hey Snips, cancel my 2 minute shower timer please

Debug

In the src/index.ts file:

// Replace 'error' with '*' to log everything
logger.enable('error')

Test

Requires mosquitto to be installed.

npm run test

In test mode, i18n output is mocked.

snips-action-timer's People

Contributors

coorfun avatar elbywan avatar mariaisabeldiazsaezsonos avatar thomas-bouvier 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.