JetBrains Space Help

Publish Dart Packages

Suppose you have a Dart package and want to publish it to the newly created Dart package repository using:

Publish packages using dart command-line tool

  1. Specify the repository URL and an access token for the dart tool:

    dart pub token add

    • is the repository URL

    • mycompany is the name of your company in Space, mydart is the repository name.

    If you are not sure about the URL, you can copy the URL of a particular repository on the Packages page.

  2. When asked for a token, specify your personal access token. You can manage the created token on the My Profile | Security | Personal Tokens page.

  3. Open the directory with your Dart project.

  4. In the project's pubspec.yml file, add the repository URL:

  5. Publish the package to the repository:

    dart pub publish

Publish Dart packages from Space Automation

For the instructions on how to publish Dart packages from Space Automation, refer to Space Automation examples.

Last modified: 30 August 2022