Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use pub workspace for the dart-pad monorepo #3041

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

johnpryan
Copy link
Contributor

This sets up a pub workspace for each of the packages in this monorepo. This lets us run dart pub get from the root of the project and take advantage of a shared analysis server.

Copy link
Member

@devoncarew devoncarew left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good generally - good to experiment with this feature. I don't know how this will interact with creating the docker images to run the backend, but I imagine we'll find that out.

In order to get this to work on the CI I think we'll need to provision using the flutter sdk instead of the dart one, given that some of the packages need flutter.

Run dart pub get
Resolving dependencies in `/home/runner/work/dart-pad/dart-pad`...
Because samples depends on flutter from sdk which doesn't exist (the Flutter SDK is not available), version solving failed.

dependency_overrides:
dartpad_shared:
path: ../dartpad_shared
# This package is managed as part of the dart-pad workspace.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As a nit in these files, perhaps move the resolution info to before the dependencies section?

@johnpryan
Copy link
Contributor Author

The pub did not create .dart_tools/package_config.json file. error is likely due to the fact that we have not finished adding support for workspaces to the flutter tool.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants