Forrest logo
back to the pio tool

pio-run:tldr:74663

pio-run: Run all targets of specified environments.
$ pio run --environment ${environment1} --environment ${environment2}
try on your machine

The command you provided is related to PlatformIO, an open-source ecosystem for IoT development.

The command pio run is used to build and process a project. It compiles the code, resolves dependencies, and generates binaries or firmware files.

The --environment flag is used to specify the build environment or configuration. In your command, it is used twice with ${environment1} and ${environment2} as arguments to specify two different environments.

Each environment usually corresponds to a specific hardware board, platform, or configuration defined in the platformio.ini configuration file within your project. By specifying multiple environments, you can build your project for multiple platforms or with different configurations.

For example, if you have two environments defined in platformio.ini, let's say "env1" for an Arduino Uno and "env2" for a Raspberry Pi, the command pio run --environment env1 --environment env2 will build the project for both the Arduino Uno and Raspberry Pi.

Note that ${environment1} and ${environment2} are placeholders in your command, and in actual usage, you need to replace them with the specific environment names you want to build.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the pio tool