Package Exports
- @invarn/cibuild
- @invarn/cibuild/dist/cli.cjs
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@invarn/cibuild) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
cibuild
Lightweight CI/CD pipeline runner for Android and iOS projects. Run your pipelines locally or on a remote runner using a simple YAML format.
Install
brew tap invarnhq/cibuild
brew install cibuildThis installs two commands: ci and cibuild (both identical).
Getting Started
There are three ways to set up a pipeline in your project:
1. Create (recommended)
Auto-detects your platform (iOS/Android), picks recommended build settings, and collects secrets from disk — fully non-interactive:
ci init --create2. Interactive
Walk through an interactive wizard to choose between creating or importing a pipeline:
ci init3. Import
Import an existing YAML pipeline file into your project:
ci init --import path/to/pipeline.ymlAll three methods scaffold the .ci/pipelines/ directory, validate dependencies, and add runtime files to .gitignore.
For the full pipeline YAML format, step catalog, and examples, see SPEC.md.
Commands
ci init # Interactive setup wizard
ci init --create # Auto-create pipeline (non-interactive)
ci init --import <path> # Import YAML pipeline (non-interactive)
ci build # Generate a standard pipeline for the current project
ci run <path> [-w <name>] # Run locally (development mode)
ci run <path> [-w <name>] --production # Run on remote runner (production)
ci run <path> [-w <name>] --validate-only # Validate only, don't execute
ci run <path> [-w <name>] --skip-validation # Skip validation, run with interactive prompts
ci validate <path> [-w <name>] # Validate pipeline (alias for --validate-only)
ci detect-platform <path> [-w <name>] # Detect platform from YAML pipeline
ci edit <path> [-w <name>] # View pipeline and edit step inputs
ci secrets add <var_name> <path> [-w <name>] # Add a secret (prompted interactively)
ci --help # Show helpSupported Formats
.yml/.yaml— YAML pipeline files.ts— TypeScript pipeline files
Development
Prerequisites
- Node.js 20+
- npm
Setup
npm installBuild (development)
Compiles TypeScript via tsc into dist/src/:
npm run buildWatch mode
npm run devTests
npm testRelease Builds
Two independent build pipelines exist depending on the distribution target.
Homebrew (native binary)
Bundles with esbuild, then compiles to a standalone macOS binary via pkg. No obfuscation — pkg embeds the JS inside the binary, which already protects the source. Obfuscation is intentionally skipped here because it encodes require() string arguments, breaking pkg's static analysis.
npm run release
# Outputs:
# dist/cibuild-macos-arm64.tar.gz
# dist/cibuild-macos-x64.tar.gznpm (obfuscated JS)
Bundles with esbuild, then obfuscates with javascript-obfuscator (base64 string encoding). Produces a single self-contained .cjs file.
npm run build:npm
# Outputs:
# dist/cli.cjs (minified + string-obfuscated)Releasing a new version
Tagging and pushing a version tag triggers the GitHub Actions release workflow, which:
- Runs
npm run releaseto build both macOS binaries - Creates a release on
invarnhq/cibuildwith the binaries attached - Auto-updates
Formula/cibuild.rbin the public tap repo with the new version and SHA256 checksums
git tag v1.0.0
git push origin v1.0.0