2. Installation#
[01] Installation types#
[02] Install rivt-uv#
This method for installing rivt is recommended for most users. The procedure for Windows is shown below. Other OS installs are similar.
Step 1. Install uv
Install uv. The recommended method for installing uv on Windows is:
winget install --id=astral-sh.uv -e
Step 2. Create rivt environment and install rivtlib
After installing uv, run the following commands to set up and activate an isolated rivt environment in the users Home directory (omit the explanatory REM lines). The commands execute the following steps:
names the uv environment in the first SET command
changes to the %HOMEPATH% (User) folder
removes any prior existing environment, cache and folders.
downloads the rivt install file.
creates a new environment and activates it.
installs rivt in the uv environment.
creates an example1 folder
downloads a rivt file and sources into the example1 folder
The commands may be downloaded and run from the command file
rivt-uv.cmd
.
@echo on
REM (1) clear any existing project, (2) create new venv
REM (3) install rivt, (4) download example
REM set rivt folder
SET rvfolder=rivt-doc1
REM go to home directory
cd %HOMEPATH%
REM double check deactivation
uv deactivate
REM double check that old project is deleted
rmdir /s /q %rvfolder%
REM (1) clean cache
uv cache clean
REM set up venv
mkdir %rvfolder%
REM change directory
cd %rvfolder%
REM (2) make venv
uv venv
REM activate venv
call .venv/scripts/activate
REM (3) install rivt from GitHub
uv pip install git+https://github.com/rivtlib-dev/rivtlib.git@main
REM (4) download example project into new folder
mkdir example1
cd example1
curl https://raw.githubusercontent.com/rivt-info/rivt-simple-single-doc/refs/heads/main/rv0000-simple-single-doc.py -O
curl https://github.com/rivt-info/rivt-simple-single-doc/blob/main/beam.png?raw=true -O -L
REM run example with (no quotes) "python rv0000-simple-single-doc.py"
cmd /k
Within the example1 folder run the rivt file:
python rv0000-simple-single-doc.py
[03] Install rivt-system#
Use Python installers and pip to install packages from PyPI. The requirements.txt file is here.
[04] Install rivt framework#
The rivt framework includes installation of the following programs:
[04] Install rivt.zip#
rivt.zip is a portable, single folder version of rivt and VSCode including libraries and extensions. It can be downloaded here.
The advantages of this installation method include:
No steps - just unzip and use.
Can be moved anywhere as a unified folder.
Ensures compatiblity and integration between libraries.
Disadvantages include:
The installation itself cannot be updated. New releases are planned monthly.
Integration with other programs can be more difficult.