Skip to content

CLI Setup

Create an xc shortcut that works from any Flutter project with xwidget_builder as a dev dependency.

macOS / Linux:

sudo sh -c 'echo "#!/bin/sh
exec dart run xwidget_builder:xc \"\$@\"" > /usr/local/bin/xc && chmod +x /usr/local/bin/xc'

Windows (admin PowerShell):

$batContent = "@echo off`r`ndart run xwidget_builder:xc %*"
Set-Content -Path "$env:USERPROFILE\AppData\Local\Microsoft\WindowsApps\xc.bat" -Value $batContent

Then use it from any project:

$ xc cloud login
$ xc cloud deploy
$ xc generate

Option 2: Run Without Installing

Run the CLI directly via Dart from your project directory:

$ dart run xwidget_builder:xc cloud login
$ dart run xwidget_builder:xc generate

Verify

$ xc --help

Or without the global command:

$ dart run xwidget_builder:xc --help

Global Options

Option Description
--version Print the XWidget Builder version number
--no-logo Suppress the XWidget logo output
--help Show usage information

These options work on any command and subcommand:

$ xc --version
$ xc generate --help
$ xc cloud deploy --help

Uninstall

macOS / Linux:

sudo rm /usr/local/bin/xc

Windows:

Remove-Item "$env:USERPROFILE\AppData\Local\Microsoft\WindowsApps\xc.bat"