Rive CLI 1.7.0
This release catches more problems before you publish. In the previewer and in captures, an image now reports a size of 0x0 until after the first frame, as on the web, so a script that reads an image's size too early breaks in the preview, not on the published page. A color written as colorValue="#282828" instead of colorValue="FF282828" now fails the build, where before the shape drew nothing. A first rive push now lets you pick the folder instead of always using the project root, rive library search lists the libraries a project can import, rive login works over SSH, and --probe and --compare check a capture's colors and changes as text. Update with rive update (curl install) or brew upgrade --cask rive-cli.
Push
๐ Pick a folder on your first push: a first rive push now opens a folder picker in your terminal, so you choose the project and the folder the file goes in. Before, you could only pick a project, and the file always landed at its root. The picker shows folders and subfolders, leaves out projects you can't write to, and lets you switch to another Workspace. In a script, pass --folder=<id> together with --project=<id> and get both ids from rive ls.
โ ๏ธ rive push --list is gone: use rive ls, which also shows folders. A first push that can't show the picker, such as rive push > log where the output goes to a file, now stops and asks for --project=<id> on the command line. Before, it quietly created the file at the project root.
๐ข Typos in ids are caught: --project and --folder now refuse anything that isn't a number. Before, --project=abc read as 0 and --project=8061oops as 8061, so a typo could create the file at the project root or in the wrong project, and link your project to that file in rive.yaml.
Sign-in and install
โ ๏ธ rive login works over SSH: rive login now always signs in with a code you approve in a browser. Before, it only worked when the browser ran on the same machine, so over SSH, in a container or with no display it hung. On a desktop it still opens the approval page with the code filled in, so it stays one click. Elsewhere it prints the URL to open on any device. --device is still accepted, so existing scripts keep working.
๐ง Browsers open on Linux: rive login and rive open now open a browser on Linux. Before, they never did.
๐ฆ The installer runs on more machines: curl ... | sh now works on Debian and Ubuntu, where it used to fail with an error and install nothing. It also no longer needs python3, so it runs on a minimal Linux image or a Mac without the Command Line Tools. Before, it stopped with install.sh needs 'python3' on PATH.
Libraries
๐ Find libraries to import: rive library search lists the libraries a project can import, with their ids. It uses the project of the linked file unless you pass --project=<id> to name one. --match=<text> filters by name and --json prints one object per line. Projects in a personal Workspace aren't supported yet, and the command says so rather than showing an empty list. Like publishing, it needs a Voyager plan or higher.
๐ค Text Input builds from the CLI: a project that uses the editor's built-in Text Input component now builds with it. Before, rive pull couldn't download the component, so it was missing from the .riv and the build told you to run rive pull, which didn't help.
๐ Library scripts come from the right publish: each library component now runs the script that was published with it. Before, if a library version mixed components from two publishes, a component could run the script from the other publish, with no error or warning.
Previews and captures
โ ๏ธ Images load as on the web: in the previewer and in captures, an image now reports a size of 0x0 during init and the first frame, then its real size once it loads, as on a web runtime. The Image object a script holds updates to the real size, so you don't need to fetch it again. A script that reads an image's width or height too early now breaks in the preview, instead of only once published. Scenes that don't read an image's size early capture exactly as before. An image in a layout set to Hug also resizes the layout once it loads. Before, it could stay 0x0.
๐ฒ Repeatable random numbers: --screenshot, --semantics and --data-dump now start math.random from a fixed seed, so a capture comes out the same on every run. --seed=<N> picks a different seed. The preview window and published pages stay random.
๐งช Ask a capture questions as text: three new flags work with --screenshot. --probe=x,y prints the color at a point in the same AARRGGBB form colorValue uses, for example probe 120,60 FF57A5E0. --compare=<png> prints how many pixels differ from an earlier capture. --scale=<factor> writes a smaller png. An agent can check that something moved or was drawn without reading a whole image.
๐ Publish locally to another folder: --output-dir=<directory> writes a --publish=local build to another folder for that run only. A relative path resolves against the project folder, and rive.yaml is left alone.
๐๏ธ Eased values no longer hitch: a DataConverterInterpolator eases a bound value to its new setting. Before, every change after the first froze the value for one frame, so the motion hitched.
๐ฑ Steadier Android previews: rive . --android no longer crashes on devices with Mali GPUs, falls back to OpenGL when Vulkan fails to start, and no longer stalls frames waiting on a script's GPU canvas.
RML (the markup the CLI compiles)
โ ๏ธ Colors that can't be read fail the build: every color attribute, like colorValue, propertyValue and highlightColor, now takes 8 hex digits of ARGB, or 6 for an opaque color. Before, #282828 or 0xff282828 built with no error and drew transparent, so the shape shipped invisible. Now the build fails with a message that shows the format:
SolidColor expects attribute colorValue to be ARGB hex: 8 digits like FF282828, or 6 for opaque, no # or 0x.๐ Angular gradients: <AngularGradient> draws a gradient that sweeps around a center point, with the same stops as <LinearGradient> and <RadialGradient> elements. Place, turn and stretch it with transformX, transformY, transformRotation, transformScaleX and transformScaleY. Stops run clockwise.
๐ข Limit what a Text Input takes: <TextInput maxCharacters="n" maxLines="n"> caps what a user can type, with 0 for no limit, and both can be bound. Typing and Enter stop at the limit, and a paste keeps only what fits. maxLines counts lines as they wrap. Text set by the file or a data bind is never trimmed.
๐ค Disabled layers stay off: a state machine layer marked disabled is now left out of the .riv, as the editor does. Before, it played in CLI builds while the editor showed it idle.
๐ชถ Disabled feathers stay off: a feather with isEnabled="false" is now left out of the .riv, with any animation keyed on it. Before, turning off an inner shadow made its fill fade to transparent.
๐ --from-remote-file opens more files: rive create --from-remote-file now accepts a file with a fire action on an Entry state, or any action on an Any, Exit or blend state. Before, it refused the whole file.
Scripting
๐งฑ GPU bind groups follow the entry points: a pipeline now builds its automatic bind group layouts from its own vertex and fragment entry points, not from the whole shader. It no longer needs bind groups for resources only other entry points use, and a draw whose bind groups don't match the pipeline now reports an error.
Built-in CLI docs (rive docs)
The docs that ship with the CLI, and what agents read to author scenes.
๐ค No more waiting on a keypress: rive docs --search and --list now always print plain lines, and --pick opens the picker. Before, when an agent ran them, they opened a picker and waited for a keypress nobody sent. --list also no longer starts with a stray row.
๐งญ Better pointers for agents: the docs now mention rive docs --search, say the debugger shows a script's local variables, and suggest keeping state you want to test in a view model, so --data-dump can read it as text.