# unexpected-cli-sandbox

> ## Configuration

Latest version **1.0.101** (published 2024-10-03) · ISC license · 0 weekly downloads

## Install

```sh
npm install unexpected-cli-sandbox
pnpm add unexpected-cli-sandbox
yarn add unexpected-cli-sandbox
bun add unexpected-cli-sandbox
```

Provides the command `unexpected-cli-sandbox`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; large bundle.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.101 |
| Published | 2024-10-03 |
| First published | 2024-06-24 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 23 |
| Unpacked size | 27.8 MB |
| Known vulnerabilities | 0 (+9 in 4 direct dependencies) |
| Install scripts | no |
| Maintainers | oleksii_kilevoi, bohdan_svyrydonov |

## Links

- npm: https://www.npmjs.com/package/unexpected-cli-sandbox
- npm.io page: https://npm.io/package/unexpected-cli-sandbox

## Dependencies (23)

- [zx](https://npm.io/package/zx.md) ^8.0.2
- [zod](https://npm.io/package/zod.md) ^3.23.4
- [cors](https://npm.io/package/cors.md) ^2.8.5
- [toml](https://npm.io/package/toml.md) ^3.0.0
- [uuid](https://npm.io/package/uuid.md) ^10.0.0
- [acorn](https://npm.io/package/acorn.md) ^8.12.1
- [axios](https://npm.io/package/axios.md) ^1.6.8
- [dayjs](https://npm.io/package/dayjs.md) ^1.11.10
- [hanji](https://npm.io/package/hanji.md) ^0.0.5
- [kleur](https://npm.io/package/kleur.md) ^4.1.5
- [esbuild](https://npm.io/package/esbuild.md) ^0.20.2
- [express](https://npm.io/package/express.md) ^4.19.2
- [openurl](https://npm.io/package/openurl.md) ^1.1.1
- [form-data](https://npm.io/package/form-data.md) ^4.0.0
- [miniflare](https://npm.io/package/miniflare.md) ^3.20240405.2
- [websocket](https://npm.io/package/websocket.md) ^1.0.34
- [acorn-walk](https://npm.io/package/acorn-walk.md) ^8.3.3
- [source-map](https://npm.io/package/source-map.md) ^0.7.4
- [body-parser](https://npm.io/package/body-parser.md) ^1.20.2
- [configstore](https://npm.io/package/configstore.md) ^6.0.0
- [json-schema-typed](https://npm.io/package/json-schema-typed.md) ^8.0.1
- [source-map-support](https://npm.io/package/source-map-support.md) ^0.5.21
- [@drizzle-team/brocli](https://npm.io/package/@drizzle-team/brocli.md) ^0.10.1

## Recent versions

- 1.0.101 (latest) — 2024-10-03
- 1.0.100 — 2024-07-19
- 1.0.99 — 2024-07-11
- 1.0.98 — 2024-07-11
- 1.0.97 — 2024-07-11
- 1.0.96 — 2024-07-09
- 1.0.95 — 2024-07-09
- 1.0.94 — 2024-07-09
- 1.0.93 — 2024-07-05
- 1.0.92 — 2024-07-05
- 1.0.91 — 2024-07-02
- 1.0.9 — 2024-07-02
- 1.0.8 — 2024-07-01
- 1.0.7 — 2024-07-01
- 1.0.6 — 2024-07-01
- … 6 more at https://npm.io/package/unexpected-cli-sandbox/versions

## README

# unexpected-cli-sandbox

## Configuration

Create a file `unexpected.json` with the following structure:

```json
{
    "workerId": "fb0eb483-c7ac-4795-a13a-af76c62db462",
    "name": "53e535f4-a",
    "projectId": "6e94a318-fc68-4e91-a5b0-f92d20640442",
    "buildDirectory": ".build",
    "env": {
        "foo": "bar",
        "number": 300
    }
}
```

**Note:** This configuration file is optional. If the configuration file does not exist, it will be created automatically.

- `workerId`: Required. Unique identifier for the worker.
- `name`: Optional. Name for the worker, limited to 10 characters.
- `buildDirectory`: Optional. Default is `.build`.
- `env`: Optional. Environment variables, either strings or numbers. If you want to bind environment variables during deployment, add them to the config.

## Commands

### `login`

Log into the system:

```bash
unexpected-cli-sandbox login
```

### `logout`

Log out of the system:

```bash
unexpected-cli-sandbox logout
```

### `build`

Build the project based on the current configuration. If a path to a folder containing the function is specified, it will build from that folder. If no path is specified, it will build from the default folder `functions`.

```bash
# Build with a specified path to the function folder
unexpected-cli-sandbox build --path /path/to/your/function

# Build from the default folder
unexpected-cli-sandbox build
```

**Options:**

- `--path`, `-p`: Path to the folder containing the function to deploy. If not specified, the default folder `functions` is used.

### `deploy`

Deploy the built project to the specified environment. If a path to a folder containing the function is specified, it will deploy from that folder. If no path is specified, it will deploy from the default folder `functions`.

```bash
# Deploy with a specified path to the function folder
unexpected-cli-sandbox deploy --path /path/to/your/function

# Deploy from the default folder
unexpected-cli-sandbox deploy
```

**Options:**

- `--path`, `-p`: Path to the folder containing the function to deploy. If not specified, the default folder `functions` is used.

### `deploy-live-query`

Deploy the live query to the specified environment.

```bash
unexpected-cli-sandbox deploy-live-query
```

### `set-trigger`

Set the trigger for a specified table.

```bash
unexpected-cli-sandbox set-trigger --table table_name
```

**Options:**

- `--table`, `-t`: Name of the table to deploy the live query to. This option is required.

### `delete-trigger`

Delete the trigger for a specified table.

```bash
unexpected-cli-sandbox delete-trigger --table table_name
```

**Options:**

- `--table`, `-t`: Name of the table to delete the trigger from. This option is required.

### `delete-live-query`

Delete the deployed live query.

```bash
unexpected-cli-sandbox delete-live-query
```

### `hello`

Receive greetings from the CLI!

```bash
unexpected-cli-sandbox hello
```

### `tail`

Tail the logs of the deployed project in real-time.

```bash
unexpected-cli-sandbox tail
```

### `delete`

Delete a worker in the project.

```bash
unexpected-cli-sandbox delete
```

## Help

To get a list of all available commands and their descriptions:

```bash
unexpected-cli-sandbox --help
```

If no path is specified for commands that require a path, the default folder `functions` will be used.

---
_Source: https://npm.io/package/unexpected-cli-sandbox · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
