From b766abdf95ab51c25a65d29d9177e1478d529c7f Mon Sep 17 00:00:00 2001 From: Tony Brix Date: Sat, 2 Jan 2021 11:33:24 -0600 Subject: [PATCH] docs: add services section to readme --- README.md | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 65bdd6d2..19c444b4 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║██║ ██║███████╗ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██║ ██║╚════██║ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║╚██████╔╝███████║ - ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝ ╚═════╝ ╚══════╝ + ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝ ╚═════╝ ╚══════╝

@@ -133,7 +133,7 @@ Dropping a file on the terminal will insert the file path into the input. This w ### Insert Selected Text -Insert and run selected text from your text editor by running the `terminus:insert-selected-text` command or ctrl-ictrl-i. ![](https://github.com/bus-stop/terminus/raw/master/resources/t-insert_selected_text.gif) @@ -187,3 +187,25 @@ The toggle is located right under the `Map Terminals To` option. | terminus:close | Close the active terminal. | alt-shift-x
or
cmd-shift-x | | terminus:close-all | Close all terminals. | –––––––––––– | | terminus:rename | Rename the active terminal. | –––––––––––– | + +## Services + +The `terminal` `v1.0.0` service is provided for other packages to interact with Terminus through Atom's [services](http://flight-manual.atom.io/behind-atom/sections/interacting-with-other-packages-via-services/) API. + +The `terminal` service provides the following methods: + +### `updateProcessEnv(object)` + +Update environment variables for any new terminals. + +### `run(string[])` + +Run commands in a new terminal. + +### `open()` + +Open a new terminal. + +### `getTerminalViews()` + +Get the current views for all open terminals.