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

fix(core): list only changed files on format:write log #10155

Merged

Conversation

meeroslav
Copy link
Contributor

Current Behavior

The format:write currently includes explicit checks on nx.json, workspace.json and tsconfig.base.json and performs write on all of them including all the files matching the provided pattern.

This results in a log containing all of the files touched, although in reality only a few of them are actually changed.

The format:check lists only files that require fixing.

Expected Behavior

The format:write should list only files that were changed during the formatting, not all of the files being checked.

This is useful for using format:write as part of the pre-commit hook and automatically add changed files to commit.

Related Issue(s)

Fixes #

@meeroslav meeroslav added the scope: core core nx functionality label May 5, 2022
@meeroslav meeroslav self-assigned this May 5, 2022
@nx-cloud
Copy link

nx-cloud bot commented May 5, 2022

☁️ Nx Cloud Report

CI is running/has finished running commands for commit 61d124f. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch


✅ Successfully ran 12 targets

Sent with 💌 from NxCloud.

@vercel
Copy link

vercel bot commented May 5, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
nx-dev ✅ Ready (Inspect) Visit Preview May 5, 2022 at 9:39AM (UTC)

@FrozenPandaz FrozenPandaz merged commit e5fd269 into nrwl:master May 6, 2022
@meeroslav meeroslav deleted the fix/list-only-diff-on-format-write branch November 8, 2022 15:32
@github-actions
Copy link

This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 17, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
scope: core core nx functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants