# CLI


<!-- WARNING: THIS FILE WAS AUTOGENERATED! DO NOT EDIT! -->

This module implements the Plash CLI functions. As they’re built with
fastcore `@call_parse` they can also be used in python directly.

------------------------------------------------------------------------

<a
href="https://github.com/AnswerDotAI/plash_cli/blob/main/plash_cli/cli.py#L87"
target="_blank" style="float:right; font-size:smaller">source</a>

### login

``` python

def login(
    token:str=None, # Token to save directly to config
    show:bool=False, # Output the current session token
):

```

*Authenticate CLI with server and save config*

CLI usage:

``` bash
plash_login --help
```

    usage: plash_login [-h] [--token TOKEN] [--show]

    Authenticate CLI with server and save config

    options:
      -h, --help     show this help message and exit
      --token TOKEN  Token to save directly to config
      --show         Output the current session token (default: False)

------------------------------------------------------------------------

<a
href="https://github.com/AnswerDotAI/plash_cli/blob/main/plash_cli/cli.py#L150"
target="_blank" style="float:right; font-size:smaller">source</a>

### deploy

``` python

def deploy(
    path:Path='.', # Path to project
    name:str=None, # Overrides the .plash file in project root if provided
    _force_data:bool=False, # Overwrite data/ directory during deployment
):

```

*Deploys app to production. By default, this command erases all files in
your app which are not in data/.* Then uploads all files and folders,
except paths starting with `.` and except the local data/ directory. If
`force_data` is used, then it erases all files in production. Then it
uploads all files and folders, including `data/`, except paths starting
with `.`.

CLI usage:

``` bash
plash_deploy --help
```

    usage: plash_deploy [-h] [--path PATH] [--name NAME] [--force_data]

    options:
      -h, --help    show this help message and exit
      --path PATH   Path to project (default: .)
      --name NAME   Overrides the .plash file in project root if provided
      --force_data  Overwrite data/ directory during deployment (default: False)

------------------------------------------------------------------------

<a
href="https://github.com/AnswerDotAI/plash_cli/blob/main/plash_cli/cli.py#L191"
target="_blank" style="float:right; font-size:smaller">source</a>

### view

``` python

def view(
    path:Path='.', # Path to project directory
    name:str=None, # Overrides the .plash file in project root if provided
):

```

*Open your app in the browser*

CLI usage:

``` bash
plash_view --help
```

    usage: plash_view [-h] [--path PATH] [--name NAME]

    Open your app in the browser

    options:
      -h, --help   show this help message and exit
      --path PATH  Path to project directory (default: .)
      --name NAME  Overrides the .plash file in project root if provided

------------------------------------------------------------------------

<a
href="https://github.com/AnswerDotAI/plash_cli/blob/main/plash_cli/cli.py#L202"
target="_blank" style="float:right; font-size:smaller">source</a>

### delete_app

``` python

def delete_app(
    path:Path='.', # Path to project
    name:str=None, # Overrides the .plash file in project root if provided
):

```

*Delete your deployed app*

CLI usage:

``` bash
plash_delete --help
```

    usage: plash_delete [-h] [--path PATH] [--name NAME] [--force]

    Delete your deployed app

    options:
      -h, --help   show this help message and exit
      --path PATH  Path to project (default: .)
      --name NAME  Overrides the .plash file in project root if provided
      --force      Skip confirmation prompt (default: False)

------------------------------------------------------------------------

<a
href="https://github.com/AnswerDotAI/plash_cli/blob/main/plash_cli/cli.py#L223"
target="_blank" style="float:right; font-size:smaller">source</a>

### start_app

``` python

def start_app(
    path:Path='.', # Path to project
    name:str=None, # Overrides the .plash file in project root if provided
):

```

*Start your deployed app*

CLI usage:

``` bash
plash_start --help
```

    usage: plash_start [-h] [--path PATH] [--name NAME]

    options:
      -h, --help   show this help message and exit
      --path PATH  Path to project (default: .)
      --name NAME  Overrides the .plash file in project root if provided

------------------------------------------------------------------------

<a
href="https://github.com/AnswerDotAI/plash_cli/blob/main/plash_cli/cli.py#L239"
target="_blank" style="float:right; font-size:smaller">source</a>

### stop_app

``` python

def stop_app(
    path:Path='.', # Path to project
    name:str=None, # Overrides the .plash file in project root if provided
):

```

*Stop your deployed app*

CLI usage:

``` bash
plash_stop --help
```

    usage: plash_stop [-h] [--path PATH] [--name NAME]

    options:
      -h, --help   show this help message and exit
      --path PATH  Path to project (default: .)
      --name NAME  Overrides the .plash file in project root if provided

------------------------------------------------------------------------

<a
href="https://github.com/AnswerDotAI/plash_cli/blob/main/plash_cli/cli.py#L258"
target="_blank" style="float:right; font-size:smaller">source</a>

### logs

``` python

def logs(
    path:Path='.', # Path to project
    name:str=None, # Overrides the .plash file in project root if provided
    mode:log_modes='build', # Choose between build or app logs
):

```

*Get logs for your deployed app*

CLI usage:

``` bash
plash_logs --help
```

    usage: plash_logs [-h] [--path PATH] [--name NAME] [--mode {build,app}] [--tail]

    options:
      -h, --help          show this help message and exit
      --path PATH         Path to project (default: .)
      --name NAME         Overrides the .plash file in project root if provided
      --mode {build,app}  Choose between build or app logs (default: build)
      --tail              Tail the logs (default: False)

------------------------------------------------------------------------

<a
href="https://github.com/AnswerDotAI/plash_cli/blob/main/plash_cli/cli.py#L290"
target="_blank" style="float:right; font-size:smaller">source</a>

### download_app

``` python

def download_app(
    path:Path='.', # Path to project
    name:str=None, # Overrides the .plash file in project root if provided
    save_path:Path='./download/', # Save path (optional)
):

```

*Download deployed app to save_path.*

CLI usage:

``` bash
plash_download --help
```

    usage: plash_download [-h] [--path PATH] [--name NAME] [--save_path SAVE_PATH]

    options:
      -h, --help             show this help message and exit
      --path PATH            Path to project (default: .)
      --name NAME            Overrides the .plash file in project root if provided
      --save_path SAVE_PATH  Save path (optional) (default: ./download/)

------------------------------------------------------------------------

<a
href="https://github.com/AnswerDotAI/plash_cli/blob/main/plash_cli/cli.py#L312"
target="_blank" style="float:right; font-size:smaller">source</a>

### app_list

``` python

def app_list(
    
):

```

*List your deployed apps*

CLI usage:

``` bash
plash_apps --help
```

    usage: plash_apps [-h] [--verbose]

    options:
      -h, --help  show this help message and exit
      --verbose   Whether to show running status as well as name: 1=running, 0=stopped (default: False)

------------------------------------------------------------------------

<a
href="https://github.com/AnswerDotAI/plash_cli/blob/main/plash_cli/cli.py#L326"
target="_blank" style="float:right; font-size:smaller">source</a>

### plash_tool_info

``` python

def plash_tool_info(
    
):

```

*Call self as a function.*

``` python
# plash_tool_info()
```

Plash tools:
&`[login, deploy, start_app, stop_app, logs, download_app, app_list]`
