Skip to content

Added dprint config and commit-on-master task#66235

Merged
jakebailey merged 63 commits intoDefinitelyTyped:masterfrom
JoshuaKGoldberg:dprint-onboarding
Oct 6, 2023
Merged

Added dprint config and commit-on-master task#66235
jakebailey merged 63 commits intoDefinitelyTyped:masterfrom
JoshuaKGoldberg:dprint-onboarding

Conversation

@JoshuaKGoldberg
Copy link
Copy Markdown
Collaborator

@JoshuaKGoldberg JoshuaKGoldberg commented Jul 31, 2023

👉 See #65993 Using a formatter for formatting (instead of lint rules) for context.

Corresponds to the changes described in #65993. This initial PR adds:

  • .github/workflows/format-and-commit.yml: adds a workflow to run dprint and commit changes
    • Note that the trigger to run on master is commented out
  • .vscode/extensions.json: recommends the dprint extension
  • .vscode/settings.template.json: sets VS Code to format with the dprint extension by default
  • dprint.json: configuration file for dprint, including "excludes" for (known or seemingly) auto-generated packages
  • README.md docs around formatting
  • package.json: a new dev dependency on dprint

Because format-and-commit.yml's commit trigger is commented out, merging this PR won't cause dprint to be applied to all files.

Co-authored-by: @jakebailey

Comment thread types/anime-quotes-api/dprint.json Outdated
Comment thread dprint.json Outdated
Comment thread dprint.json Outdated
Comment thread .github/workflows/format-and-commit.yml
Comment thread .github/workflows/format-and-commit.yml Outdated
Comment thread .github/workflows/format-check.yml Outdated
Comment thread .github/workflows/format-check.yml Outdated
Comment thread .gitignore Outdated
Comment thread .github/workflows/format-and-commit.yml Outdated
Comment thread .github/workflows/format-and-commit.yml
@jakebailey
Copy link
Copy Markdown
Member

Just as a meta-note about the workflows, I'd prefer if job configs were to come last; they get long and having them at the top will push info like the name/triggers/etc down to the bottom when it's usually important info. I don't think I've seen jobs stuck at the top before.

Comment thread .github/workflows/format-check.yml Outdated
@typescript-bot
Copy link
Copy Markdown
Contributor

@jakebailey, @sandersn, @andrewbranch, @peterblazejewicz Thank you for reviewing this PR! The author has pushed new commits since your last review. Could you take another look and submit a fresh review?

@typescript-bot
Copy link
Copy Markdown
Contributor

@sandersn, @jakebailey, @andrewbranch, @peterblazejewicz Thank you for reviewing this PR! The author has pushed new commits since your last review. Could you take another look and submit a fresh review?

@jakebailey
Copy link
Copy Markdown
Member

#66235 (comment) shows the new dangerbot output.

@jakebailey
Copy link
Copy Markdown
Member

Okay, this PR should be ready to go, whenever we're ready to flip the switch! It'll immediately format about 141 files.

Copy link
Copy Markdown
Member

@andrewbranch andrewbranch left a comment

Choose a reason for hiding this comment

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

👏

@typescript-bot typescript-bot added Maintainer Approved Self Merge This PR can now be self-merged by the PR author or an owner and removed Unreviewed No one showed up to review this PR, so it'll be reviewed by a DT maintainer. labels Oct 6, 2023
@typescript-bot
Copy link
Copy Markdown
Contributor

@jakebailey, @sandersn, @peterblazejewicz Thank you for reviewing this PR! The author has pushed new commits since your last review. Could you take another look and submit a fresh review?

@jakebailey
Copy link
Copy Markdown
Member

Ready to merge

@jakebailey
Copy link
Copy Markdown
Member

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants