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

support building with npm #68

Open
escapewindow opened this issue Jul 31, 2020 · 4 comments
Open

support building with npm #68

escapewindow opened this issue Jul 31, 2020 · 4 comments

Comments

@escapewindow
Copy link
Contributor

Currently, both CI and release builds assume we will build the xpi via yarn build. There are at least a couple repos where developers want npm building support (not sure if this is npm build or npm run build ?).

The actual line in question is here. That's super easy to change. We can key that off of XPI_INSTALL_TYPE or another env var. (If another env var, we should add a corresponding xpi-manifest key and surface that as an env var, like we do with XPI_INSTALL_TYPE.

We should:

  • verify what npm build support means
  • see which repos need it - currently firefox voice + searchengine devtools?
  • we can test what the change will do in our staging manifest repo (I need to move this to a shared location.) We need to make sure that we don't leave anyone broken.
    • if we find there are xpis that we will never need to release again, we can mark them active: false to avoid needing to patch them
    • deal with any bustage, which may include patches to a number of source repos
  • we probably need corresponding changes to xpi-template for CI, since it shares the same build docker image
  • open PRs to the various repos, land them roughly at the same time
@escapewindow
Copy link
Contributor Author

The complexity here is not in making the xpi-manifest repo change, but in making sure that we don't leave CI or any given supported repo broken in doing so.

@ianb
Copy link
Contributor

ianb commented Jul 31, 2020

In some documentation it is suggested that the existence of yarn.lock implies it's a yarn project, and package-lock.json implies npm. Using that same pattern here would avoid new project configuration.

@escapewindow
Copy link
Contributor Author

@ianb xpi-manifest doesn't clone every repo when creating its graph, so it doesn't know what files are in the project. Doing so may slow things down.

@escapewindow
Copy link
Contributor Author

Additional information:

  • searchengine-devtools is an npm project, but yarn build works.
  • if we solve the package-lock.json issue in firefox voice and switch it back to npm install, similarly yarn build may just work, and we can close this issue.

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

No branches or pull requests

2 participants