FABulous Configuration Variables

FABulous can use environment variables to configure options, paths and projects. We distinguish between two types of environment variables: global and project specific environment variables.

  • Global environment variables are used to configure FABulous itself. They always start with FAB_.

  • Project specific environment variables are used to configure a specific FABulous project. They always start with FAB_PROJ_.

All environment variables can be set in the shell before running FABulous or can be set via .env files.

.env File Locations

Scope

Location

How to use

User global

~/.config/FABulous/.env

Created automatically or manually

Global (explicit)

Any path

Pass via --globalDotEnv CLI argument

Project (auto-detected)

<project_dir>/.FABulous/.env

Placed inside your project

Project (explicit)

Any path

Pass via --projectDotEnv CLI argument

Note

Environment variables set in the shell always have the highest priority, followed by project-specific .env files, then global .env files.

Global Environment Variables

Variable

Environment Variable

Type

Default

User Value

Description

user_config_dir

FAB_USER_CONFIG_DIR

Path

(dynamic)

/path/to/file

-

oss_cad_suite

FAB_OSS_CAD_SUITE

Path

None

/path/to/file

-

yosys_path

FAB_YOSYS_PATH

Path

yosys

/path/to/file

-

nextpnr_path

FAB_NEXTPNR_PATH

Path

nextpnr-generic

/path/to/file

-

iverilog_path

FAB_IVERILOG_PATH

Path

iverilog

/path/to/file

-

vvp_path

FAB_VVP_PATH

Path

vvp

/path/to/file

-

ghdl_path

FAB_GHDL_PATH

Path

ghdl

/path/to/file

-

klayout_path

FAB_KLAYOUT_PATH

Path

klayout

/path/to/file

-

openroad_path

FAB_OPENROAD_PATH

Path

openroad

/path/to/file

-

fabulator_root

FAB_FABULATOR_ROOT

Path

None

/path/to/file

-

models_pack

FAB_MODELS_PACK

Path

None

/path/to/file

-

switch_matrix_debug_signal

FAB_SWITCH_MATRIX_DEBUG_SIGNAL

bool

False

true / false

-

editor

FAB_EDITOR

str

None

any string

-

verbose

FAB_VERBOSE

int

0

1, 2

-

debug

FAB_DEBUG

bool

False

true / false

-

pdk_root

FAB_PDK_ROOT

Path

None

/path/to/file

-

pdk

FAB_PDK

str

None

any string

-

pdk_hash

FAB_PDK_HASH

str

None

any string

-

fabric_die_area

FAB_FABRIC_DIE_AREA

tuple

(0, 0, 1000, 1000)

[0, 0, 1000, 1000]

-

windows_warning_acknowledged

FAB_WINDOWS_WARNING_ACKNOWLEDGED

bool

False

true / false

-

Project Specific Environment Variables

Variable

Environment Variable

Type

Default

User Value

Description

proj_dir

FAB_PROJ_DIR

Path

(dynamic)

/path/to/file

-

proj_lang

FAB_PROJ_LANG

HDLType

HDLType.VERILOG

verilog, vhdl, sv

-

proj_version_created

FAB_PROJ_VERSION_CREATED

Version

0.0.1

1.2.3

-

proj_version

FAB_PROJ_VERSION

Version

-

1.2.3

-

Interactive CLI Settables

These variables can be set and get interactively in the FABulous CLI using the set and get commands.

Usage:

FABulous> set <variable> <value>
FABulous> get <variable>

Variable

Type

Description

projectDir

Path

The directory of the project

csvFile

Path

The fabric file

verbose

bool

verbose output

force

bool

force execution