simonhaenisch/prettier-plugin-organize-imports

Adding this plugin breaks github actions

pitis opened this issue · 3 comments

pitis commented

Hello there,
I've been using this module for a long time, but now when I upgraded to prettier 3.1.0 and to 3.2.4 of this package, everything works fine but on github actions. For reference, my .prettierrc:

{
  "semi": false,
  "singleQuote": true,
  "trailingComma": "es5",
  "plugins": ["prettier-plugin-organize-imports"]
}

and my github action

name: static checks

on:
  pull_request:
  push:
    branches:
      - main

concurrency:
  group: ${{ github.workflow }}-${{ github.ref }}
  cancel-in-progress: true

jobs:
  static-checks:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - uses: actions/setup-node@v2
        with:
          node-version: '20'
          cache: 'npm'
      - run: npm i
      - run: npm run format:check
      - run: npm run lint

this all worked fine before and also works fine if I remove the plugins array

need more info:

  • which versions did you upgrade from?
  • what's the error?
pitis commented

@simonhaenisch sorry for not specifying before, the plugin version before was "2.3.4".
The error is it finds some files that are not formatted and it can't run, but when I run the checker or the formatter on local machine, it says no changes need to be made.

I will try to get today an example repo

Hey sry completely lost track of this... did you get the issue resolved? Closing for now, please re-open if you still have that issue.