Hey, our early access is open! Simply sign up to get started!

unistry CLI Commands

unistry

The root command of the unistry CLI.

Usage

  •  
  • unistry [flag] [command]

Commands

Command Description
init Generate configuration file and authenticate CLI
help Help about any command
tree Interacting with centralised history (utilises the configuration file)
version Print the CLI's version string

Flags

Flag Description
--auth-token Auth token to use
--config path to config file to use
-h,--help Prints the help for the unistry command

unistry init

The unistry init AUTHTOKEN  command creates a default configuration file and saves the passed auth token to it.

 

When unistry init  is run with no passed arguments, the set-up wizard will be started, to assist the user with creating an ideal configuration file for their desired experience when using unistry CLI.

 

Auth tokens, both permanent and ephemeral, can be generated on the security page of the web app.

 

Note, if a configuration file exists in the default path, this command will fail. 

Usage

 
  • unistry init [argument:AUTHTOKEN] [argument:PUBCERT_REF] [flag]

Arguments

Argument Description
AUTHTOKEN Auth token to add to configuration file
PUBCERT_REF Absolute path to or base64 encoded public RSA certificate

Flags

Flag Description
--help Provides the help doc for the unistry init command

Examples

 

unistry init

unistry init "0x9x8xD94dcfGorncyKwt.kxT4rOiMq3xZvZXC8Sot6"

unistry init "0x9x8xD94dcfGorncyKwt.kxT4rOiMq3xZvZXC8Sot6" "/Users/user/.ssh/id_rsa.pub"

unistry help

The unistry help  command provides the help docs for the targetted command. Specific commands can be targeted by giving the target command’s path from its relation to the unistry root command.

 

Note, you can access the docs by using each command’s  --help flag.

Usage

 

  • unistry help [COMMAND_PATH]

Examples

unistry help init

unistry help tree import

unistry tree

The unistry tree command provides access to the centralised history and is also the tree feature’s root command.

 

When using the tree command,  it is important to remember that the tree is kept and shown in its encrypted state by default unless specified to do otherwise in the configuration file. Users can also explicitly declare the --decrypt flag, which will unencrypt their unistry tree*.

 

*Note users must have their private key specified in their configuration file or pass its absolute path or base64 encoded cert using --path. Users can use the available flags in combination, for example, unistry tree --size 100 --page 2 --decrypt -p /path/to/private/cert etc.

Usage

 
  • unistry tree [command] [flag]

Commands

Command Description
import Generate configuration file and authenticate CLI
push Help about any command

Flags

Flag Description
--compact Displays commands in one-liner form
--decrypt Decrypts tree's commands
--detail Displays commands with maximum context
--filter [string] A space separated list of words to filter commands on
-h, --help Provides the help doc for the unistry tree command
--page [int] Handles pagination. The page number to output (default 1)
-p, --path The absolute path to or base64 encoding of private key
--size The number of commands to return per page (max: 150)

Examples

 

unistry tree

unistry tree --detail

unistry tree --decrypt -p /path/to/private/key

unistry tree --size 100 --page 2

unistry tree --filter "foo bar"

unistry tree import

The unistry tree import command consumes and processes piped command line history and pushes it to the centralised unistry tree.

 

By default, users must declare explicitly --push to push their commands to the platform. Users can also configure the import command to behave how they want by declaring their desired experience in their configuration file.

Usage

 
  • unistry tree import [flags]

Flags

Flag Description
-m, --commit-message [string] A short message (up to 125 characters) to include with commands
-h, --help Provides the help doc for the unistry tree command
--ignore-history-commands Ignore any commands starting with 'history' found in piped history
--ignore-regex [string] Ignore any commands that match specified regex from piped history
--ignore-unistry-command Ignore any commands starting with 'unistry' found in piped history
--match-regex [string] Take only the commands that match specified regex from piped history
--no-colour Disables colour in command sync summary output
-p, --path The absolute path to or base64 encoding of private key
--size The number of commands to return per page (max: 150)

Examples

history | unistry tree import

history | tail 50 | unistry tree import --push

history | unistry tree import --ignore-unistry-commands

history | unistry tree import -m "foo bar" -s "extra foo" --push

history | unistry tree import --ignore-regex "^bar"

history | unistry tree import --match-regex "^foo"

history | unistry tree import --no-duplicates --optimised-parse

unistry version

The unistry version  command displays the current version and build of the unistry CLI installed on the system.

 

If you’re ever unable to utilise features outlined in the configuration file, it is always good to make sure the  latest version of unistry CLI is installed.

Usage

 

  • unistry version [flags]

Flags

Flag Description
--help Provides the help doc for the unistry version command
-o,--output Output format. One of: json|yaml|wide|short (default "wide")

Examples

 

 

unistry version

unistry version -o json

unistry version -o yaml

unistry version --short

Securely unify your command-line experience across your devices and shells

All rights reserved 2023