Skip to content

Metadata File (rush.yml)

Shreyash Saitwal edited this page Jun 15, 2022 · 5 revisions

The metadata file, rush.yml, is the replacement of the App Inventor annotations like DesignerComponent, UsesLibraries, UsesNativeLibraries, and UsesAssets. It is written in YAML format and is responsible for defining your extension's metadata like its name, description, dependencies, and assets it requires, etc.

Supported Fields

Field name Is required? Description
name ✔️ The name of your extension
description ✔️ User-facing description of your extension.
homepage Your extensions homepage (could be an URL to your extension's website, documentation page, etc.)
license The license agreement for the end-users of the extension. This could be a remote URL or path to the local license file relative to the project root.
min_sdk Minimum Android SDK level required by your extension.
deps The dependencies (libraries) of your extension.
Note: Entries must be defined in the YAML list format.
version.name The version name of the current version of your extension.
version.number ✔️ The version number of the current version of your extension. If you want to auto-increment the version number with every release build, use auto as a value.
assets.icon Your extension's icon. Could be an image or an URL to a remote image. The icon should be available inside the assets directory if it's not an URL.
assets.other The assets required by your extension. Defined assets must be available inside the assets directory.
Note: Entries must be defined in the YAML list format.
build.release.optimize Indicates whether your extension should be optimized or not when you generate a release build of your extension.
Default value: false.
build.kotlin.enable Enables Kotlin support for your extension. Read more here.
build.desugar.enable Enables code desugaring which lets you use Java 8 language features, like lambda expressions, in your extensions. Supported language features are listed here.
Default value: false.
build.desugar.desugar_deps Enables code desugaring for your extension's dependencies. Set this to true if you encounter such errors while building.
Default value: false.

IDE Support

You can enable IntelliSense features like auto-complete and syntactic error reporting in the following IDEs:

Note: Auto-completion might not work for some recently added fields, like build.kotlin and build.desugar.

  • IntelliJ IDEA

    1. Open Settings.

    2. Go Languages & Frameworks > Schemas and DTDs > JSON Schema Mappings.

    3. Click on the + icon.

    4. Then select New Schema.

    5. Give the schema a name, and in Schema file or URL paste the below URL:

      https://raw.githubusercontent.com/shreyashsaitwal/rush-cli/main/schema/rush.json
      
    6. Then click on the other + icon, then select Add file and type rush.yml.

    7. Click OK

  • Visual Studio Code

    1. Install YAML extension.

    2. Open settings.json file.

    3. Copy and paste the following to it:

      "yaml.schemas": {
        "https://raw.githubusercontent.com/shreyashsaitwal/rush-cli/main/schema/rush.json": "rush.yml",
      },
Clone this wiki locally