Menu

This is documentation for the next version of Alloy. For the latest stable release, go to the latest version.

Open source

sys

The sys namespace contains functions related to the system.

sys.env

The sys.env function gets the value of an environment variable from the system Alloy is running on. If the environment variable does not exist, sys.env returns an empty string.

Examples

> sys.env("HOME")
"/home/alloy"

> sys.env("DOES_NOT_EXIST")
""