Statements | Branches | Functions | Lines |
---|---|---|---|
$ npm install -g site-theme-cli
$ site-theme-cli COMMAND
running command...
$ site-theme-cli (--version)
site-theme-cli/1.0.0-alpha.2 linux-x64 node-v18.17.0
$ site-theme-cli --help [COMMAND]
USAGE
$ site-theme-cli COMMAND
...
site-theme-cli auth ACCESSTOKEN
site-theme-cli help [COMMANDS]
site-theme-cli theme install
site-theme-cli theme preview
site-theme-cli theme pull
site-theme-cli theme push
site-theme-cli theme watch
Authorizes Square Online CLI with Access Token.
USAGE
$ site-theme-cli auth ACCESSTOKEN [--verbose] [-f] [--skipPermissionsCheck]
ARGUMENTS
ACCESSTOKEN Square Connect Access Token
FLAGS
-f, --force Overwrite existing Access Token
--skipPermissionsCheck Skip the permissions check for Access Token. By default this will check to see that the token
has all the required permissions
GLOBAL FLAGS
--verbose Print all API logs in console.
DESCRIPTION
Authorizes Square Online CLI with Access Token.
Visit https://developer.squareup.com/ for more information.
EXAMPLES
$ site-theme-cli auth SQUARE_CONNECT_ACCESS_TOKEN
Display help for site-theme-cli.
USAGE
$ site-theme-cli help [COMMANDS] [-n]
ARGUMENTS
COMMANDS Command to show help for.
FLAGS
-n, --nested-commands Include all nested commands in the output.
DESCRIPTION
Display help for site-theme-cli.
See code: @oclif/plugin-help
Installs theme on a Square Online site.
USAGE
$ site-theme-cli theme install [--verbose] [--siteId <value>]
FLAGS
--siteId=<value> ID of Square Online site on which you would like to install a theme, use to skip site selector step.
GLOBAL FLAGS
--verbose Print all API logs in console.
DESCRIPTION
Installs theme on a Square Online site.
EXAMPLES
$ site-theme-cli theme install
Prints the development preview links for Square Online custom theme sites.
USAGE
$ site-theme-cli theme preview [--verbose] [--siteId <value>]
FLAGS
--siteId=<value> ID of Square Online site to you would like to preview, use to skip site selector step.
GLOBAL FLAGS
--verbose Print all API logs in console.
DESCRIPTION
Prints the development preview links for Square Online custom theme sites.
EXAMPLES
$ site-theme-cli theme preview
Clone Square Online Theme Files Locally
USAGE
$ site-theme-cli theme pull [--verbose] [--siteId <value>] [--themeId <value>] [--accessToken <value>] [--yes]
[--themeDir <value>]
FLAGS
--accessToken=<value> Use this flag to pass in an access token. If not passed the CLI will look for an access token
saved during "auth" command.
--siteId=<value> The Square Online site id that you would like to pull files from.
--themeDir=<value> Path to theme directory. If the directory does not exist it will be created.
--themeId=<value> The theme id that you would like to pull files from.
--yes Use this flag to skip the confirmation prompts
GLOBAL FLAGS
--verbose Print all API logs in console.
DESCRIPTION
Clone Square Online Theme Files Locally
EXAMPLES
$ site-theme-cli theme pull
Push your local theme files to your Square Online site. Files with the following patterns will be ignored by default: /_darcs/,/CVS/,/config.yml/,/node_modules/,/.git/,/.DS_Store/,/.soignore/,/.dockerignore/,/.gitmodules/, as well as any patterns within the /.soignore file
USAGE
$ site-theme-cli theme push [--verbose] [--themeDir <value>] [--siteId <value>] [--themeId <value>]
[--omitDelete] [--accessToken <value>] [--yes]
FLAGS
--accessToken=<value> Use this flag to pass in an access token. If not passed the CLI will look for an access token
saved during "auth" command.
--omitDelete If set the CLI will skip any delete operations during syncing
--siteId=<value> The Square Online site id that you would like to push files to.
--themeDir=<value> Path to theme directory.
--themeId=<value> The theme id that you would like to push files to.
--yes Use this flag to skip the confirmation prompts
GLOBAL FLAGS
--verbose Print all API logs in console.
DESCRIPTION
Push your local theme files to your Square Online site. Files with the following patterns will be ignored by default:
/_darcs/,/CVS/,/config.yml/,/node_modules/,/.git/,/.DS_Store/,/.soignore/,/.dockerignore/,/.gitmodules/, as well as
any patterns within the /.soignore file
EXAMPLES
$ site-theme-cli theme push
Watch your theme directory and automatically upload file changes to Square Online. Files with the following patterns will be ignored by default: /_darcs/,/CVS/,/config.yml/,/node_modules/,/.git/,/.DS_Store/,/.soignore/,/.dockerignore/,/.gitmodules/ as well as any patterns within the /.soignore file
USAGE
$ site-theme-cli theme watch [--verbose] [--themeDir <value>] [--siteId <value>] [--themeId <value>]
[--hotReload] [--omitDelete] [--autoPush]
FLAGS
--autoPush Automatically push local changes when theme directory is out of sync
--hotReload Set this flag to print the preview links and enable hot reloading
--omitDelete If set the CLI will skip any delete operations during syncing
--siteId=<value> The id of the Square Online site you would like to sync to.
--themeDir=<value> Path to theme directory for watching.
--themeId=<value> The theme you would like to sync files to.
GLOBAL FLAGS
--verbose Print all API logs in console.
DESCRIPTION
Watch your theme directory and automatically upload file changes to Square Online. Files with the following patterns
will be ignored by default:
/_darcs/,/CVS/,/config.yml/,/node_modules/,/.git/,/.DS_Store/,/.soignore/,/.dockerignore/,/.gitmodules/ as well as any
patterns within the /.soignore file
EXAMPLES
$ site-theme-cli theme watch
The theme pull
and theme push
commands support automated workflows. Passing in an accessToken flag will skip using any on saved through the auth
command. themeDir
flags can be either relative or absolute. yes
will skip any steps that usually require a user confirmation to continue.
site-theme-cli theme pull --siteId=site_693636287506607541 --themeId=site_theme_63ab1ab0-59e1-11ef-8cee-23c1d5cbb712 --themeDir=./brisk-theme --accessToken=YOUR_ACCESS_TOKEN --yes
site-theme-cli theme push --siteId=site_693636287506607541 --themeId=site_theme_63ab1ab0-59e1-11ef-8cee-23c1d5cbb712 --themeDir=./brisk-theme --accessToken=YOUR_ACCESS_TOKEN --yes
- Install Node.
- Install NVM.
nvm use
npm ci