Skip to content
P

Prettier Action

GitHub action for running prettier on your projects pull requests

by creyDFree

#2888in Productivity
0In stores

Description

Prettier Action is a GitHub action that runs Prettier on your files inside a workflow, so code style is applied automatically to the reposit…

Highlights

  • Runs Prettier inside GitHub workflows
  • Dry mode fails on unformatted files
  • Configurable commit, push and message options
  • Pin a Prettier version or add plugins
  • Working directory for subfolder projects

Ratings & Reviews

No ratings yet

Be the first to rate Prettier Action.

People also visit

C

Create Pull Request

A GitHub action to create a pull request for changes

Productivity
Launch
A

Add And Commit

Automatically commit changes made in your workflow run directly to your repo

Productivity
Launch
S

setup-pre-commit

Set up Husky pre-commit hooks with lint-staged

AI Skills
Get
A

authoring-github-workflows

Author and review GitHub Actions workflow YAML safely

AI Skills
Get
G

github-workflow-automation

Advanced GitHub Actions workflow automation

AI Skills
Get
G

github

GitHub patterns using gh CLI for pull requests, stacked PRs, code review

AI Skills
Get

Prettier Action FAQ

What does it do?

It runs Prettier on your repository inside a GitHub workflow and commits the changes, so formatting is applied without a manual step.

How do I check formatting without changing files?

Turn on dry mode. Files are not changed, and the action fails if any file is unformatted. The README recommends using --check in prettier_options.

Which Prettier version does it use?

The latest version by default. The prettier_version input lets you pin a specific one.

Can it format only some files?

Yes. prettier_options sets which files Prettier runs on, and file_pattern sets which files git add stages.

Is it open source?

Yes. The source is public on GitHub at creyD/prettier_action.

What are the best Prettier Action alternatives?

Popular alternatives to Prettier Action include Create Pull Request, Add And Commit and Slash Command Dispatch. See all Prettier Action alternatives

Developer Stuff

Badges