Skip to content

Commit

Permalink
feat: update docs build README
Browse files Browse the repository at this point in the history
  • Loading branch information
chmod77 committed Nov 29, 2024
1 parent 231c867 commit 708bad8
Show file tree
Hide file tree
Showing 3 changed files with 3,203 additions and 1,637 deletions.
50 changes: 34 additions & 16 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,35 +2,53 @@

## Prerequisites

* `conda` (We recommend Miniconda installed with an [official installer](https://docs.conda.io/projects/miniconda/en/latest/index.html#latest-miniconda-installer-links))
* `uv`

* [`conda-lock`](https://github.com/conda/conda-lock)
For MacOS / Linux:

```bash
curl -LsSf https://astral.sh/uv/install.sh | sh
```

## Set up the build environment

In the `flyteorg/flyte` root directory do:
For Windows, use irm to download the script and execute it with iex:

```bash
$ conda-lock install --name monodocs-env monodocs-environment.lock.yaml
$ conda activate monodocs-env
$ pip install ./flyteidl
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"

powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/0.5.5/install.ps1 | iex"
```

This creates a new environment called `monodocs-env` with all the dependencies needed to build the docs. You can choose a different environment name if you like.
To install via PyPi:

```bash

## Building the docs
pipx install uv
```

In the `flyteorg/flyte` root directory make sure you have activated the `monodocs-env` (or whatever you called it) environment and do:
or

```bash
# need to set this to a fake value to build the docs locally
$ export DOCSEARCH_API_KEY=fake-api-key
```bash

pip install uv
```


## Setup the build environment

```bash
$ make docs
uv sync

uv pip install ./flyteidl

```

The resulting `html` files will be in `docs/_build/html`.
## Building the docs

```bash
export DOCSEARCH_API_KEY=fake-api-key
export FLYTEKIT_LOCAL_PATH=<PATH_TO_LOCAL_FLYTEKIT_REPO>
export FLYTESNACKS_LOCAL_PATH=<PATH_TO_LOCAL_FLYTESNACKS_REPO>

uv run make docs
```
The resulting `html` files will be in `docs/_build/html`.
Loading

0 comments on commit 708bad8

Please sign in to comment.