Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

chore: prefix all nx package scripts with npx#7988

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Conversation

JoshuaKGoldberg
Copy link
Member

PR Checklist

Overview

Prefixes all the commands that usenx withnpx.

@typescript-eslint
Copy link
Contributor

Thanks for the PR,@JoshuaKGoldberg!

typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community.

The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately.

Thanks again!


🙏Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently onhttps://opencollective.com/typescript-eslint.

@netlifyNetlify
Copy link

netlifybot commentedNov 24, 2023
edited
Loading

Deploy Preview fortypescript-eslint ready!

NameLink
🔨 Latest commit518dff3
🔍 Latest deploy loghttps://app.netlify.com/sites/typescript-eslint/deploys/656078b5000bc700084e87fe
😎 Deploy Previewhttps://deploy-preview-7988--typescript-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 96 (🟢 up 5 from production)
Accessibility: 100 (no change from production)
Best Practices: 92 (no change from production)
SEO: 98 (no change from production)
PWA: 80 (no change from production)
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to yourNetlify site configuration.

Copy link

@merceyzmerceyz left a comment
edited
Loading

Choose a reason for hiding this comment

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

I'm not too familiar with the inner workings ofnpx but wont this use whatever version is installed globally and if none is found prompt the user to install it?

This repository also doesn't usenpm so this doesn't seem like an ideal solution.

If what you're after is using thenx version installed in the root workspace then you should useyarn run -T nx orrun -T nx.
If not then you should addnx as a dependency to each workspace that needs it.

Refhttps://yarnpkg.com/getting-started/qa#how-to-share-scripts-between-workspaces
Ref#7987 (comment)

@bradzacher
Copy link
Member

Could we just add nx as a dep and then prefix with yarn instead?

@JoshuaKGoldberg
Copy link
MemberAuthor

JoshuaKGoldberg commentedNov 24, 2023
edited
Loading

Swapping"start": "npx nx start" with"start": "yarn nx start" yields:

josh ~/repos/typescript-eslint/packages/website $ yarn startUsage Error: Couldn't find a script named "nx".

Same withyarn run nx start. I've been reading throughhttps://nx.dev/core-features/run-tasks & co but don't see any recommendations around this?

cc@JamesHenry too

@bradzacher
Copy link
Member

Yeah I'm not quite sure - I would have thought thatyarn nx would run the locally installed verison ofnx - do we need to addnx as a dependency to each and every package so that yarn can see it?

IDK how Yarn3 works - you didn't need to do that with yarn1 as it'd just look in the parent folder.

@JamesHenry
Copy link
Member

How frustrating yeah this definitely worked fine in yarn 1. FWIW you can also install nx globally one time and it will always work as well, it will resolve your most local installation possible before attempting to run the actually globally installed code.

I’ll need to play with this to get a real sense of what might optimal here, I’m afraid I lost all of the weekend because of moving apartments and my next availability will be this coming weekend, so feel free to do whatever makes the most sense in the immediate term if this is blocking

JoshuaKGoldberg reacted with thumbs up emoji

@JoshuaKGoldbergJoshuaKGoldberg merged commit4dae083 intotypescript-eslint:mainNov 28, 2023
@JoshuaKGoldbergJoshuaKGoldberg deleted the prefix-nx-with-npx branchNovember 28, 2023 14:26
@github-actionsgithub-actionsbot locked asresolvedand limited conversation to collaboratorsDec 6, 2023
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.
Reviewers

@merceyzmerceyzmerceyz requested changes

@JamesHenryJamesHenryAwaiting requested review from JamesHenry

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

Repo: Many dev commands require a global nx command
4 participants
@JoshuaKGoldberg@bradzacher@JamesHenry@merceyz

[8]ページ先頭

©2009-2025 Movatter.jp