Skip to content

Commit 7d9f5fb

Browse files
committed
Update docs
1 parent 1997831 commit 7d9f5fb

3 files changed

Lines changed: 34 additions & 21 deletions

File tree

README.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,14 @@ To get started quickly on a fresh Ubuntu 24.04 instance (e.g, a Digital Ocean dr
8080

8181
**WARNING:** Always review downloaded scripts prior to running them so that you know what going to happen to your machine.
8282

83-
### Lazy Mode
84-
Stack is written in Python and so needs a recent Python 3 on the machine. It also needs either docker or podman installed, and these utilities: git, jq. The [full installation instructions](./docs/install.md) show how to get these but if you're allready set up, proceed:
83+
### Install with uv
84+
If you have [uv](https://docs.astral.sh/uv/getting-started/installation/) installed:
85+
```bash
86+
uv tool install --from git+https://github.com/bozemanpass/stack stack
87+
```
88+
89+
### Download a release
90+
Stack is written in Python and so needs a recent Python 3 on the machine. It also needs either docker or podman installed, and these utilities: git, jq. The [full installation instructions](./docs/install.md) show how to get these but if you're already set up, proceed:
8591

8692
Stack is distributed as a single-file self-extracting script. The latest release can be downloaded like this:
8793
```bash

docs/CONTRIBUTING.md

Lines changed: 9 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,7 @@ Suitable for developers either modifying or debugging the orchestrator Python co
1010

1111
In addition to the pre-requisites listed in the [README](/README.md), the following are required:
1212

13-
1. Python venv package
14-
This may or may not be already installed depending on the host OS and version. Check by running:
15-
```
16-
$ python3 -m venv
17-
usage: venv [-h] [--system-site-packages] [--symlinks | --copies] [--clear] [--upgrade] [--without-pip] [--prompt PROMPT] ENV_DIR [ENV_DIR ...]
18-
venv: error: the following arguments are required: ENV_DIR
19-
```
20-
If the venv package is missing you should see a message indicating how to install it, for example with:
21-
```
22-
$ apt install python3.10-venv
23-
```
13+
1. [uv](https://docs.astral.sh/uv/getting-started/installation/) — used for dependency management and virtual environments.
2414

2515
### Install
2616

@@ -29,19 +19,20 @@ In addition to the pre-requisites listed in the [README](/README.md), the follow
2919
$ git clone https://github.com/bozemanpass/stack.git
3020
```
3121

32-
2. Enter the project directory:
22+
2. Enter the project directory:
3323
```
3424
$ cd stack
3525
```
3626

37-
3. Setup the virtualenv:
27+
3. Install dependencies:
3828
```
39-
$ source ./scripts/developer-mode-setup.sh
29+
$ ./scripts/developer-mode-setup.sh
4030
```
31+
This runs `uv sync`, which creates a `.venv` virtual environment and installs all dependencies.
4132

42-
4. Verify installation:
33+
4. Verify installation:
4334
```
44-
$ (venv) stack
35+
$ uv run stack
4536
Usage: stack [OPTIONS] COMMAND [ARGS]...
4637
4738
BPI stack
@@ -68,11 +59,11 @@ In addition to the pre-requisites listed in the [README](/README.md), the follow
6859

6960
## Build a zipapp (single file distributable script)
7061

71-
Use shiv to build a single file Python executable zip archive of stack:
62+
Use shiv (via `uvx`) to build a single file Python executable zip archive of stack:
7263

7364
1. Run shiv to create a zipapp file:
7465
```
75-
$ (venv) ./scripts/build_shiv_package.sh
66+
$ ./scripts/build_shiv_package.sh
7667
```
7768
This creates a file under `./package/` that is executable outside of any venv, and on other machines and OSes and architectures, and requiring only the system Python3:
7869

docs/install.md

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,23 @@ curl -SL https://github.com/docker/compose/releases/download/v2.11.2/docker-comp
2323
chmod +x ~/.docker/cli-plugins/docker-compose
2424
```
2525

26-
Next decide on a directory where you would like to put the stack program. Typically, this would be
26+
### Install with uv (recommended)
27+
28+
If you have [uv](https://docs.astral.sh/uv/getting-started/installation/) installed, you can install stack directly from the git repository:
29+
30+
```bash
31+
uv tool install --from git+https://github.com/bozemanpass/stack stack
32+
```
33+
34+
This installs `stack` into an isolated environment and adds it to your PATH. To update to the latest version:
35+
36+
```bash
37+
uv tool upgrade stack
38+
```
39+
40+
### Install from a downloaded release
41+
42+
Decide on a directory where you would like to put the stack program. Typically, this would be
2743
a "user" binary directory such as `~/bin` or perhaps `/usr/local/bin/stack` or possibly just the current working directory.
2844

2945
Now, having selected that directory, download the latest release from [this page](https://github.com/bozemanpass/stack/releses) into it (we're using `~/bin` below for concreteness but edit to suit if you selected a different directory). Also be sure that the destination directory exists and is writable:

0 commit comments

Comments
 (0)