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

Switch away from using npm for metro #2212

Merged
merged 3 commits into from
Nov 5, 2024
Merged

Conversation

anthonyshull
Copy link
Contributor

We don't have an organizational npm account so it will probably be easier and faster in the short-term to not publish metro's JS via npm. That means dotcom has to make some changes to accommodate.

@anthonyshull anthonyshull added the dev-blue Deploy to dev-blue label Nov 4, 2024
@anthonyshull anthonyshull marked this pull request as ready for review November 5, 2024 00:11
@anthonyshull anthonyshull requested a review from a team as a code owner November 5, 2024 00:11
@thecristen thecristen added the dev-blue Deploy to dev-blue label Nov 5, 2024
@@ -58,4 +58,6 @@ runs:
shell: bash
run: |
git config --global url."https://github.com/".insteadOf ssh://git@github.com/
npm install -g husky@latest
Copy link
Contributor Author

Choose a reason for hiding this comment

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

📓 This is necessary to run the command below.

@@ -58,4 +58,6 @@ runs:
shell: bash
run: |
git config --global url."https://github.com/".insteadOf ssh://git@github.com/
npm install -g husky@latest
npm install --prefix assets --package-lock-only
Copy link
Contributor Author

Choose a reason for hiding this comment

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

📓 This is necessary for install to pick up mbta_metro as a path.

@@ -101,6 +101,7 @@ jobs:
priv
react_renderer/dist/app.js
key: ci-application-cache-${{ github.sha }}
- run: npm install --prefix assets -S -install-links deps/mbta_metro/priv/
Copy link
Contributor Author

Choose a reason for hiding this comment

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

📓 This is necessary to install mbta_metro from a path, but getting its deps and putting them in node_modules.

Comment on lines +40 to +47
RUN npm i -g husky@latest

WORKDIR /root/assets

RUN npm install --package-lock-only
RUN npm ci --ignore-scripts
RUN npm install -S -install-links ../deps/mbta_metro/priv/

Copy link
Contributor Author

Choose a reason for hiding this comment

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

📓 This just does all three of those things in the build process.

Copy link
Collaborator

Choose a reason for hiding this comment

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

cool. we should probably create an alias to group these commands at some point

Copy link
Collaborator

@thecristen thecristen left a comment

Choose a reason for hiding this comment

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

No blockers here!

@anthonyshull anthonyshull merged commit a1f2c3a into main Nov 5, 2024
23 of 24 checks passed
@anthonyshull anthonyshull deleted the ags/use-non-npm-metro branch November 5, 2024 17:26
@thecristen thecristen removed the dev-blue Deploy to dev-blue label Nov 7, 2024
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