Git Product home page Git Product logo

jimmy-zhening-luo / scriptable Goto Github PK

View Code? Open in Web Editor NEW
3.0 2.0 0.0 4.98 MB

A compelling use of Scriptable is using JavaScript to control custom iOS actions (see iOS Shortcuts), device-side and home automation, and on-screen Widgets. This project extends the Scriptable ecosystem by providing system classes like File, Url, Repository, Config, Data — making all the above safer and easier to do.

License: MIT License

TypeScript 99.88% JavaScript 0.12%
ios scriptable shortcuts typescript

scriptable's Introduction

@jimbojet/scriptable

Azure Publish (PROD.main)

What is Scriptable?

A compelling use of Scriptable is using JavaScript to control custom iOS actions (see iOS Shortcuts), device-side and home automation, and on-screen Widgets.

Scriptable provides all the classes needed to interact with the above native iOS features and with the user.

What is @jimbojet/scriptable?

@jimbojet/scriptable extends the Scriptable ecosystem by providing system classes like File, Url, Repository, Setting, Data -- making it a lot safer and easier to e.g. write your code in a separate source controlled environment and then deploy it and test with a single button; write your code in TypeScript and then pull the JavaScript; write user libraries; create and mutate files; read and write data for a script you write without having to touch the file system; obtain a secret file from your local disk and load it into Keychain for later use (and configure re-load / key roll); define and read settings for a given script (with auto-merging of app-level and user-level settings, and error-handling if settings are improperly configured or otherwise invalid); get results from and return results to iOS Shortcuts; create and mutate URLs, making requests and handling responses for HTTP requests and x-callback-urls, opening the URL in Safari or WebView, opening other iOS url schemes.

How to use

Note: this project is not production-ready. It runs without failing on my device and with my shortcuts but is still a WIP since it doesn't have a build test suite and it doesn't have a user guide / operating instructions. However, if you are an existing Scriptable moderate user, you should be able to figure out how to use it by starting from the ./boot/!boot/Boot.js module, and its corresponding Scriptable boot runner script, ./boot/!boot.js.

scriptable's People

Contributors

jimmy-zhening-luo avatar

Stargazers

David Dennison avatar Dakota Lorance avatar Riyaadh Mahomed avatar

Watchers

 avatar Kostas Georgiou avatar

scriptable's Issues

Action:Web

Dependency: URL Validator

Inherit: Browser

Classes:

  • Callback
  • Endpoint
  • Download (more constrained Endpoint with write ops)
  • Navigate (incl. b64 & webview)

System: Implement Secret keyroll

  • versioned keys (same name + timestamp + optional unique version name)
  • accept any version of key (with option to specify specific set of keys or only keys newer than T time, by default forever, if global TTL set, then by TTL)
  • delete specific key version (specific key, keys in date range, keys before or after a given date, list of key versions by version name or date)
  • set a global TTL

System: Implement Secret

  • load a named secret from keychain
  • store a named secret in keychain (specify overwrite or not)
  • delete a named secret in keychain
  • load a named secret from #Secret local filesystem
  • store a named secret on #Secret local filesystem (specify overwrite or not)
  • delete a named secret on #Secret local filesystem
  • load a named secret from either keychain or filesystem (can specify precedence order)
  • delete a named secrete from both keychain and filesystem
  • port a named secret from keychain to filesystem (specify whether or not to delete from keychain)
  • port a named secret from filesystem to keychain (specify whether or not to delete from filesystem)

Action:Notification

e.g.

  1. Click wolfram api response to do a full page lookup
  2. Click GPT response to continue chat
  3. Click translation to open in Pleco / edit in text editor

Type: Date

  • Format
  • compare
  • mutate
  • safe read and write to file
  • safe read and write to natural language text field (e.g. Things item due date)

V7: Docs

  • Purpose
  • Features
  • Limitations
  • How to use

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.