[BUG] Can't use custom config
Closed this issue · 5 comments
Chosey98 commented
What exactly happened?
Steps to reproduce the behavior:
- Run the action with
prettier_options: --config ./.prettier.json --write **/*.js
- See error
What should've happened?
It should have used the file that's there but instead I got
Error: Invalid configuration file `events/error.js`: ENOENT: no such file or directory, open '/github/workspace/.prettier.json'
Chosey98 commented
@creyD you said in #41 that it works for you but it keeps on erroring out for me no idea why... The file is there though
https://gyazo.com/9726ba833df302c44d1f0435298b8f27
creyD commented
Could you try with .github/workflows/.prettier.json?
Chosey98 commented
It worked tysm but now it errors because it cant push to the protected branch is there a way to be able to push to it?
Chosey98 commented
My main branch is protected due having any changes on sub branches first
creyD commented
No. When you want to use the action to push to a branch it can't be protected. You could use the dry run feature for this, but then it doesn't apply the changes.