Getting started
To get started with Sysand, first follow the instructions for installing Sysand, then try out the steps in the tutorial.
Installation
Sysand is written in Rust programming language. To build it, install Rust and run the following command in the terminal:
cargo install sysand --git=https://github.com/sensmetry/sysand.git
With Sysand installed, you can now create a model interchange project as shown in the following subsection.
Tutorial
Model interchange projects
A model interchange project is a collection of SysML v2 (.sysml) or KerML (.kerml)
files with additional metadata such as project name, versions, and the list of
projects on which it depends. To create a new project called my_project run:
$ sysand new my_project
Creating interchange project `my_project`
This creates a new directory (my_project) and populates it with a minimal
interchange project, consisting of two files .project.json and .meta.json.
Inside the directory, we can ask for a basic overview of the project.
$ cd my_project
$ sysand info
Name: my_project
Version: 0.0.1
No usages.
Source files
The project we created in the previous subsection contains no source files as can be seen by running the following command:
$ sysand sources
<NO OUTPUT>
Before we can add source files to the project, we need to create them. Create
MyProject.sysml file with the following content:
package MyProject;
Now, we can add MyProject.sysml to our project by running the following
command:
$ sysand include MyProject.sysml
Including files: ["MyProject.sysml"]
The file will now be listed by sysand sources, which can serve as the input
to a SysML v2 processing environment.
$ sysand sources
/path/to/my_project/MyProject.sysml
The following subsection shows how to add dependencies to our project.
Dependencies
Effectively all projects depend on elements defined in other projects. The key benefit of Sysand is that it can automatically manage project dependencies for you.
KerML (and by extension in SysML v2) specification calls a project dependency a
usage. Each usage is identified by an Internationalized Resource Identifier
(IRI) with
an optional version constraint. To add dependencies, use the sysand add
command. The simplest way to use it is to give an IRI to a package you want to
install from the Sysand Package Index. You can find the
IRI (and the full install command) in the card of the package on the index
website. For example, to install the standard Function Library, run:
$ sysand add urn:kpar:function-library
Adding usage: urn:kpar:function-library
Creating env
Syncing env
Installing urn:kpar:semantic-library 1.0.0
Installing urn:kpar:data-type-library 1.0.0
Installing urn:kpar:function-library 1.0.0
It is also possible to install packages from the URL that points to the .kpar
file as shown in the following snippet:
$ sysand add https://www.omg.org/spec/KerML/20250201/Function-Library.kpar
Adding usage: https://www.omg.org/spec/KerML/20250201/Function-Library.kpar
Creating env
Syncing env
Installing https://www.omg.org/spec/KerML/20250201/Semantic-Library.kpar 1.0.0
Installing https://www.omg.org/spec/KerML/20250201/Data-Type-Library.kpar 1.0.0
Installing https://www.omg.org/spec/KerML/20250201/Function-Library.kpar 1.0.0
Adding a dependency may take a few seconds to run, as it will find and install
the project (and any transitive usages) into a new local environment. Once
finished, this will have created a file called sysand-lock.toml and a directory
sysand_env. The former records the precise versions installed, so that the
same installation can be reproduced later. The latter directory will contain a
local installation of the added project, as well as any of its (transitive)
usages. sysand-lock.toml is sufficient to reproduce sysand_env; therefore, we
recommend checking in sysand-lock.toml into your version control system and
adding sysand_env to .gitignore.
We can confirm that the usage was successfully added by running the info
command again:
$ sysand info
Name: my_project
Version: 0.0.1
Usages:
https://www.omg.org/spec/KerML/20250201/Semantic-Library.kpar
If we run sysand source again, it will now include all source files of the
set of (transitive) dependencies.
$ sysand sources
/path/to/my_project/sysand_env/7afe310696b522f251dc21ed6086ac4b50a663969fd1a49aa0aa2103d2a674ad/1.0.0.kpar/Metaobjects.kerml
/path/to/my_project/sysand_env/7afe310696b522f251dc21ed6086ac4b50a663969fd1a49aa0aa2103d2a674ad/1.0.0.kpar/Performances.kerml
/path/to/my_project/sysand_env/7afe310696b522f251dc21ed6086ac4b50a663969fd1a49aa0aa2103d2a674ad/1.0.0.kpar/Links.kerml
/path/to/my_project/sysand_env/7afe310696b522f251dc21ed6086ac4b50a663969fd1a49aa0aa2103d2a674ad/1.0.0.kpar/SpatialFrames.kerml
/path/to/my_project/sysand_env/7afe310696b522f251dc21ed6086ac4b50a663969fd1a49aa0aa2103d2a674ad/1.0.0.kpar/Clocks.kerml
...
Environments
When we executed sysand add in the previous subsection, it implicitly created
and synchronized an environment for us. For users familiar with Python, Sysand
environments serve the same purpose as Python virtual environments: they store
dependencies needed for a specific project.
We can see everything installed in the local environment using sysand env list:
$ sysand env list
https://www.omg.org/spec/KerML/20250201/Data-Type-Library.kpar 1.0.0
https://www.omg.org/spec/KerML/20250201/Function-Library.kpar 1.0.0
https://www.omg.org/spec/KerML/20250201/Semantic-Library.kpar 1.0.0
If you want to recreate the environment on a new machine, make sure you have not
only your project files, but also sysand-lock.toml and execute the following
command:
$ sysand sync
Creating env
Syncing env
Installing https://www.omg.org/spec/KerML/20250201/Data-Type-Library.kpar 1.0.0
Installing https://www.omg.org/spec/KerML/20250201/Semantic-Library.kpar 1.0.0
Installing https://www.omg.org/spec/KerML/20250201/Function-Library.kpar 1.0.0
Packaging projects for distribution
To package your project for distribution, run sysand build:
$ sysand build
Building kpar: /path/to/my_project/output/my_project.kpar
This command creates a my_project.kpar file that can be installed in a
different project using sysand.
Project information and metadata
Contents of interchange project information (.project.json)
and metadata (.meta.json) files are specified in KerML
specification. Sysand imposes extra
requirements for some fields, as documented below. These extra requirements are
imposed to achieve better interoperability and aid in machine processing.
Fields
license
Specification does not have any requirements for license format. Sysand
encourages the use of SPDX License Expressions to specify licenses.
By default Sysand rejects license strings that are not valid SPDX License
Expressions. Examples of valid expressions:
MIT- MIT licenseMIT OR Apache-2.0- MIT and/or Apache-2.0 license applies, chosen by the userLicenseRef-My-License- a custom license (LicenseRef-part is mandatory in this case). This should be used when the license used is not in SPDX License list.
See the specification and license list for more information. If a project’s license is not given, it is assumed that the project cannot be used under any license.
As specified by REUSE project, license files should be included at
the top level directory of the project inside LICENSES subdirectory. License
file name should match the license field’s value with .txt appended, except
when using composite expressions (those containing OR, AND or WITH). In
those cases include all the license/exception files mentioned in the expression.
For the complete set of SPDX license and exception files, see the SPDX GitHub
repository. Custom licenses (such as LicenseRef-MyCustom) result in
license file name LicenseRef-MyCustom.txt.
Each file should have its license specified at the top in a comment. See REUSE spec for details.
version
Specification does not impose any constraints on how the version should look like, it only recommends to use Semantic Versioning (SemVer). Sysand strongly encourages users to use SemVer and by default does not accept non-SemVer 2.0.0 version strings in its commands.
versionConstraint
versionConstraint field can be used to constrain the allowed versions
of a specific project within a usage.
Version constraints use the same syntax as Rust’s Cargo. The usage resolution version selection mechanism is only implemented for semantic version constraints and semantic versions of used projects. Sysand will not be able to correctly (or at all) select versions for usages that do not adhere to SemVer.
See below for details.
Version constraint syntax
A version constraint consists of one or more version comparators,
separated by commas. Each version comparator consists of
an operator and a version. Version is a SemVer with possibly omitted
trailing components, e.g. 1.0.0, 2.3, 5, 2.3.4-beta are all
valid in a comparator. The missing components are ignored
when matching against a version. Note that versions can only be
truncated in version constraints, but not in any other context.
In order for the version to satisfy a constraint, it must match all
of the comparators in the constraint.
Version comparison operators are listed below. In the examples,
:= denotes equivalence between expressions.
No operator
A bare version specifier, such as 1.2.3, 2, 3.1.
It is exactly equivalent to a caret (^) operator.
Caret operator
Caret operator (^) allows SemVer compatible updates.
Leaving off the caret is a simplified equivalent syntax. It is recommended to use the caret syntax for added clarity.
Versions are considered compatible if their left-most non-zero major/minor/patch component is the same. This is different from SemVer which considers all pre-1.0.0 packages to be incompatible.
Examples:
^1.2.3 := 1.2.3 := >=1.2.3, <2.0.0
^1.2 := 1.2 := >=1.2.0, <2.0.0
^1 := 1 := >=1.0.0, <2.0.0
^0.2.3 := 0.2.3 := >=0.2.3, <0.3.0
^0.2 := 0.2 := >=0.2.0, <0.3.0
^0.0.3 := 0.0.3 := >=0.0.3, <0.0.4
^0.0 := 0.0 := >=0.0.0, <0.1.0
^0 := 0 := >=0.0.0, <1.0.0
Tilde operator
Tilde operator (~) specifies a minimal version with some ability to update.
If a major, minor, and patch version or only a major and minor
version is specified, only patch-level changes are allowed. If only a major
version is given, then minor- and patch-level changes are allowed.
Examples:
~1.2.3 := >=1.2.3, <1.3.0
~1.2 := >=1.2.0, <1.3.0
~1 := >=1.0.0, <2.0.0
Wildcard operator
Wildcard operator (*) allows for any version where the wildcard is
positioned.
Examples:
* := >=0.0.0
1.* := >=1.0.0, <2.0.0
1.2.* := >=1.2.0, <1.3.0
Equals operator
Equals operator (=) means the exact version is required.
Since the version in a comparator may be partial, only the
parts specified are required to match exactly.
Examples:
=1.2.3 := >=1.2.3, <1.2.4
=1.2 := >=1.2.0, <1.3.0
=1 := >=1.0.0, <2.0.0
Comparison operators
Comparison operators (<, <=, >, >=) are the most basic,
as all the other comparators can be equivalently translated
to (possibly multiple) comparison comparators. If only one
comparison operator is given, the allowed versions range has
no opposite end.
Examples:
>=1.2.0
>1 := >=2.0.0
<2 := <2.0.0
<=1.5 := <1.6.0
Multiple comparators
As mentioned and shown in the examples above, multiple version comparators
can be used in a single constraint when separated with a comma, e.g.,
>=1.2, <1.5.
All comparators in a constraint must be satisfied, so a non-overlapping
constraint like <1.2, ^1.2.2 is unsatisfiable.
Pre-releases
Version constraints exclude pre-release versions, such as 1.0.0-alpha,
unless specifically asked for, i.e. the exact same version with any
pre-release tag must be used in a comparator in order for that
comparator to try to match the pre-release versions.
Pre-release versions are considered to be lower than regular versions in SemVer spec. Comparators specifying a pre-release tag can also match regular versions.
Examples:
- constraint
1.0will not be satisfied by version1.0.0-alpha - constraint
>=1.0.0-beta.2, <2.0.0-alpha.5will be satisfied by version1.2.3-rc.2 - constraint
>=5.4.2-beta1will be satisfied by versions5.4.2,6.2.0and5.4.2-rc, but not5.4.3-alpha - constraint
^1.2.3-rcwill be satisfied by version1.2.3
Version metadata
Version metadata, such as 1.0.0+21AF26D3, is ignored and
should not be used in version requirements.
More information
See Cargo docs, semver crate docs
(semver crate is used by both Sysand and Cargo for version selection)
and SemVer specification for more detailed information
regarding version constraints and semantic versioning.
Commands
Commands available for sysand
sysand init
Create new project in current directory
Usage
sysand init [OPTIONS]
Description
Create new project in current directory, i.e. create .project.json and
.meta.json files.
Options
--name <NAME>: Set the project name. Defaults to the directory name.--version <VERSION>: Set the version. Defaults to0.0.1.
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand new
Create new project in given directory
Usage
sysand new [OPTIONS] <PATH>
Description
Create new project at <PATH>, i.e. a new directory containing .project.json
and .meta.json.
Arguments
<PATH>: Path to the new project.
Options
--name <NAME>: Set the project name. Defaults to the directory name.--version <VERSION>: Set the version. Defaults to0.0.1.
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand add
Add usage to project information
Usage
sysand add [OPTIONS] <IRI> [VERSION_CONSTRAINT]
Description
Adds IRI and optional version constraint to list of usages in the project
information file .project.json. By default this will also update the lockfile
and sync the local environment (creating one if not already present).
Arguments
<IRI>: IRI identifying the project to be used[VERSION_CONSTRAINT]: A constraint on the allowable versions of a used project Assumes that the project uses Semantic Versioning SeeversionConstraintdocs for details
Options
--no-lock: Do not automatically resolve usages (and generate lockfile)--no-sync: Do not automatically install dependencies
Dependency options
--index [<INDEX>...]: URLs for indexes to use when resolving dependencies, in addition to the default indexes.--default-index [<DEFAULT_INDEX>...]: Set and override URL:s of the default indexes (by default ‘https://beta.sysand.org’)--no-index: Do not use any index when resolving this usage--include-std: Include usages of KerML/SysML v2 standard libraries if present
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand remove
Remove usage from project information
Usage
sysand remove [OPTIONS] <IRI>
Description
Removes all instances of IRI from list usages in the project information file
.project.json. By default this will also update the lockfile and sync the local
environment (creating one if not already present).
Arguments
<IRI>: IRI identifying the project usage to be removed
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand include
Include model interchange files in project metadata
Usage
sysand include [OPTIONS] [PATHS]...
Description
Takes all files given by PATHS and adds them to project metadata index and
checksum list in .meta.json for the current project. By default the checksum is
not computed and is left blank (with algorithm as "None").
Current project is determined as in sysand print-root and if none is found uses the current directory instead.
Arguments
[PATHS]...: File(s) to include in the project
Options
--compute-checksum: Compute and add file (current) SHA256 checksum--no-index-symbol: Do not detect and add top level symbols to index
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand exclude
Exclude model interchange files from project metadata
Usage
sysand exclude [OPTIONS] [PATHS]...
Description
Takes all files given by PATHS and removes all instances of them to project
metadata index and checksum list in .meta.json for the current project.
Current project is determined as in sysand print-root and if none is found uses the current directory instead.
Arguments
[PATHS]...: File(s) to exclude from the project
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand build
Build a KerML Project Archive (KPAR)
Usage
sysand build [OPTIONS] [PATH]
Description
Creates a KPAR file from the current project.
Current project is determined as in sysand print-root and if none is found uses the current directory instead.
Arguments
[PATH]: Path giving where to put the finished KPAR. Defaults tooutput/<project name>.kparoroutput/project.kparif no name is found
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand lock
Create or update lockfile
Usage
sysand lock [OPTIONS]
Description
Resolves all usages in project information for current project and generates a
lockfile sysand-lock.toml in the project root directory with exact versions and
sources for all dependencies.
Current project is determined as in sysand print-root and if none is found uses the current directory instead.
Dependency options
--index [<INDEX>...]: URLs for indexes to use when resolving dependencies, in addition to the default indexes.--default-index [<DEFAULT_INDEX>...]: Set and override URL:s of the default indexes (by default ‘https://beta.sysand.org’)--no-index: Do not use any index when resolving this usage--include-std: Include usages of KerML/SysML v2 standard libraries if present
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand env
Create a local sysand_env environment for installing dependencies
Usage
sysand env [OPTIONS]
Description
Creates an empty sysand_env environment for the current project if no existing
environment can be found, and otherwise leaves it unchanged.
Current project is determined as in sysand print-root and if none is found uses the current directory instead.
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand env install
Install project in sysand_env
Usage
sysand env install [OPTIONS] <IRI> [VERSION]
Description
Installs a given project and all it’s dependencies in sysand_env for current project.
Current project is determined as in sysand print-root and if none is found uses the current directory instead.
If no existing sysand_env is found, a new one will be created in the same way
as sysand env.
Arguments
<IRI>: IRI identifying the project to be installed[VERSION]: Version to be installed
Options
--path <PATH>: Local path to interchange project--allow-overwrite: Allow overwriting existing installation--allow-multiple: Install even if another version is already installed--no-deps: Don’t install any dependencies
Dependency options
--index [<INDEX>...]: URLs for indexes to use when resolving dependencies, in addition to the default indexes.--default-index [<DEFAULT_INDEX>...]: Set and override URL:s of the default indexes (by default ‘https://beta.sysand.org’)--no-index: Do not use any index when resolving this usage--include-std: Include usages of KerML/SysML v2 standard libraries if present
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand env uninstall
Uninstall project in sysand_env
Description
Uninstalls a given project in sysand_env.
Usage
sysand env uninstall [OPTIONS] <IRI> [VERSION]
Arguments
<IRI>: IRI identifying the project to be uninstalled[VERSION]: Version to be uninstalled
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand env list
List projects installed in sysand_env
Usage
sysand env list [OPTIONS]
Description
List projects installed in sysand_env by IRI and version.
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand env sources
List source files for an installed project and (optionally) its dependencies
Usage
sysand env sources [OPTIONS] <IRI> [VERSION]
Description
Prints the paths to the source files (separated by newlines) for an installed project and (optionally) its dependencies. Is intended to be machine readable.
By default sources for standard libraries are not included, as they are typically shipped with your language implementation.
Arguments
<IRI>: IRI of the (already installed) project for which to enumerate source files[VERSION]: Version of project to list sources for
Options
--no-deps: Do not include sources for dependencies--include-std: Include (installed) KerML/SysML v2 standard libraries
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand sync
Sync sysand_env to lockfile, creating a lockfile and sysand_env if needed
Usage
sysand sync [OPTIONS]
Description
Installs all projects in the current projects lockfile sysand-lock.toml from
the sources listed, into the local sysand_env environment.
If a lockfile is not found, a new lockfile will be generated from the usages in the project information in the same way as sysand lock.
If no existing sysand_env is found, a new one will be created in the same way
as sysand env.
Current project is determined as in sysand print-root and if none is found uses the current directory instead.
Dependency options
--index [<INDEX>...]: URLs for indexes to use when resolving dependencies, in addition to the default indexes.--default-index [<DEFAULT_INDEX>...]: Set and override URL:s of the default indexes (by default ‘https://beta.sysand.org’)--no-index: Do not use any index when resolving this usage--include-std: Include usages of KerML/SysML v2 standard libraries if present
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand info
Resolve and describe current project or one at at a specified path or IRI/URL
Usage
sysand info [OPTIONS]
sysand info [OPTIONS] <COMMAND>
Description
Prints out the information contained in the .project.json file for the specified
project, defaulting to current project if no project is specified. Optionally an
extra command can be given to get or set values in .project.json and .meta.json.
Current project is determined as in sysand print-root and if none is found uses the current directory instead.
Options
--path <PATH>: Use the project at the given path instead of the current project--iri <PATH>: Use the project with the given IRI/URI/URL instead of the current project--auto-location <AUTO_LOCATION>: Use the project with the given location, trying to parse it as an IRI/URI/URL and otherwise falling back to a local path--no-normalise: Do not try to normalise the IRI/URI when resolving
Dependency options
--index [<INDEX>...]: URLs for indexes to use when resolving dependencies, in addition to the default indexes.--default-index [<DEFAULT_INDEX>...]: Set and override URL:s of the default indexes (by default ‘https://beta.sysand.org’)--no-index: Do not use any index when resolving this usage--include-std: Include usages of KerML/SysML v2 standard libraries if present
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand sources
List source files for the current project and (optionally) its dependencies
Usage
sysand sources [OPTIONS]
Description
Prints the paths to the source files (separated by newlines) for the current project and (optionally) its dependencies. Is intended to be machine readable.
By default sources for standard libraries are not included, as they are typically shipped with your language implementation.
Current project is determined as in sysand print-root and if none is found uses the current directory instead.
Options
--no-deps: Do not include sources for dependencies--include-std: Include (installed) KerML/SysML v2 standard libraries
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
sysand print-root
Prints the root directory of the current project
Usage
sysand print-root [OPTIONS] <IRI>
Description
Tries to find the current project by starting in the current directory end then iteratively going up the parent directories until a project directory is found.
A project directory is considered to be any directory containing either a
.project.json or a .meta.json file.
Global options
-v,--verbose: Use verbose output-q,--quiet: Do not output log messages--no-config: Disable discovery of configuration files--config-file <CONFIG_FILE>: Give path to ‘sysand.toml’ to use for configuration-h,--help: Print help
Configuration
Sysand offers three ways of configuring it’s behavior:
- command line options
- environment variables
- configuration files
Command line options override corresponding environment variables, while both take priority over (but not always overriding) options in configuration files.
Configuration files
Sysand will look for a sysand.toml file in the current directory or in the
current project directory (see print-root command) if such
has been found. Automatic discovery of configuration files can be disabled with
the command line option --no-config or setting the environment variable
SYSAND_NO_CONFIG to true.
The command line option --config-file (or environment variable SYSAND_CONFIG_FILE)
can be used to specify the path to an additional config file.
Configurable options
Indexes
Sysand defaults to using the index beta.sysand.org but it is possible to specify additional indexes or override this default index.
URLs for additional indexes can be specified with the command line argument --index.
Multiple indexes can be given by invoking the argument multiple times, or by passing
a comma separated list of URLs. The corresponding environment variable is SYSAND_INDEX
and also accepts comma separated lists of URLs.
Indexes specified with command line arguments or environment variables are prioritized when resolving dependencies but do not override indexes defined in configuration files.
The command line argument --default-index (and environment variable
SYSAND_DEFAULT_INDEX) functions the same as --index but will override the default
index https://beta.sysand.org and any default indexes defined in configuration
files.
Defining an index in a configuration file
To add an index with the URL https://example.index.org simple add the following
entry to your sysand.toml:
[index]
url = "https://example.index.org"
To override the default index add default = true:
[index]
url = "https://example.index.org"
default = true
Indexes are prioritized in the order they are given, with default indexes always having lower priority compared to regular indexes.