Skip to content

Commit

Permalink
Merge pull request #190 from jurij-jukic/kit-build-start-package
Browse files Browse the repository at this point in the history
New Section: `kit build-start-package`
  • Loading branch information
jurij-jukic authored May 13, 2024
2 parents 91ec702 + 2c1c51e commit 4e1a70b
Show file tree
Hide file tree
Showing 3 changed files with 83 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
- [`new`](./kit/new.md)
- [`build`](./kit/build.md)
- [`start-package`](./kit/start-package.md)
- [`build-start-package`](./kit/build-start-package.md)
- [`remove-package`](./kit/remove-package.md)
- [`dev-ui`](./kit/dev-ui.md)
- [`inject-message`](./kit/inject-message.md)
Expand Down
3 changes: 2 additions & 1 deletion src/kit-dev-toolkit.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
* [`kit new`](./kit/new.md)
* [`kit build`](./kit/build.md)
* [`kit start-package`](./kit/start-package.md)
* [`kit remove-package`](./kit/start-package.md)
* [`kit build-start-package`](./kit/build-start-package.md)
* [`kit remove-package`](./kit/remove-package.md)
* [`kit dev-ui`](./kit/dev-ui.md)
* [`kit inject-message`](./kit/inject-message.md)
* [`kit run-tests`](./kit/run-tests.md)
Expand Down
80 changes: 80 additions & 0 deletions src/kit/build-start-package.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
# `kit build-start-package`

`kit build-start-package` builds, installs and starts the indicated package directory, or the current working directory if none supplied, e.g.,

```
kit build-start-package foo
```

or

```
kit build-start-package
```

## Discussion

`kit build-start-package` runs [`kit build`](./build.md) followed by [`kit start-package`](./start-package.md).

## Arguments

```
$ kit build-start-package --help
Build and start a Kinode package
Usage: kit build-start-package [OPTIONS] [DIR]
Arguments:
[DIR] The package directory to build [default: /home/nick/git/kit]
Options:
-p, --port <NODE_PORT> Node port: for use on localhost (overridden by URL) [default: 8080]
-u, --url <URL> Node URL (overrides NODE_PORT)
--no-ui If set, do NOT build the web UI for the process; no-op if passed with UI_ONLY
--ui-only If set, build ONLY the web UI for the process
-s, --skip-deps-check If set, do not check for dependencies
--features <FEATURES> Pass these comma-delimited feature flags to Rust cargo builds
-h, --help Print help```
```

### Optional positional arg: `DIR`

The package directory to build, install and start on the node; defaults to the current working directory.

### `--port`

short: `-p`

For nodes running on localhost, the port of the node; defaults to `8080`.
`--port` is overridden by `--url` if both are supplied.

### `--url`

short: `-u`

The URL the node is hosted at.
Can be either localhost or remote.
`--url` overrides `--port` if both are supplied.

### `--no-ui`

Do not build the web UI for the process.
Does nothing if passed with `--ui-only`.

### `--ui-only`

Build ONLY the UI for a package with a UI.
Otherwise, for a package with a UI, both the package and the UI will be built.

### `--skip-deps-check`

short: `-s`

Don't check for dependencies.

### `--features`

Build the package with the given [cargo features](https://doc.rust-lang.org/cargo/reference/features.html).

Features can be used like shown [here](https://doc.rust-lang.org/cargo/reference/features.html#command-line-feature-options).
Currently the only feature supported system-wide is `simulation-mode`.

0 comments on commit 4e1a70b

Please sign in to comment.