LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

pio-ci

Run continuous integration builds for PlatformIO projects

TLDR

Build library in CI
$ pio ci --lib [.] --board [uno] [examples/Blink]
copy
Build with multiple boards
$ pio ci --board [uno] --board [esp32dev] [src/]
copy
Build with project config
$ pio ci --project-conf [platformio.ini] [src/]
copy
Exclude files from the build
$ pio ci --exclude [src/examples] --board [esp32dev] [src/]
copy
Pass project options inline
$ pio ci --board [uno] -O "lib_deps=[ArduinoJSON]" [src/]
copy
Build with verbose output
$ pio ci --board [uno] --verbose [src/]
copy

SYNOPSIS

pio ci [OPTIONS] [SRC]

DESCRIPTION

pio ci runs continuous integration builds for PlatformIO projects. It builds source files against specified boards without requiring an existing project structure. Using the provided source and library contents, PlatformIO initialises a new project in a build directory and processes it via the pio run command. Commonly used in CI/CD pipelines.

PARAMETERS

-l, --lib path

Source code which will be copied to the build directory's lib folder. Can be specified multiple times.
-b, --board id
Build project with automatically pre-generated environments based on board settings. Can be specified multiple times.
--exclude path
Exclude directories and/or files from the build directory. Path must be relative to the PlatformIO project within the build directory. Supports glob patterns.
-c, --project-conf file
Build project using a pre-configured platformio.ini file.
-O, --project-option option
Pass additional project configuration options. Can be specified multiple times for different options.
-e, --environment name
Process specified environments declared in the project configuration. Can be specified multiple times.
--build-dir path
Path to directory where PlatformIO will initialise the new project. Defaults to a temporary directory.
--keep-build-dir
Don't remove the build directory after the build process.
-v, --verbose
Show detailed information when processing environments.

SEE ALSO

pio-run(1), pio-test(1), pio(1)

Copied to clipboard
Kai