dscvitc / dscvitchennai

GDSC VIT Chennai Official website
https://gdscvitc.eu.org/
MIT License
23 stars 42 forks source link

Github Actions "prettier-action" throws error #104

Open vaibhavTekk opened 1 year ago

vaibhavTekk commented 1 year ago

Description

This repo uses prettier-action to use prettier and format the code to maintain consistency across the codebase, but currently it's broken and now checks are failing.

Documentation and resources: https://github.com/creyD/prettier_action#problem-with-npm-v9-19022023

Expected Behaviour

prettier Checks should pass successfully on pull requests.

What happened?

Automated checks for the pull request fails when it occurs

image

Version

npm v9

What browsers are you seeing the problem on?

No response

Relevant log output

Run creyD/prettier_action@v4.2
  with:
    dry: true
    prettier_options: --check **/*.{js,md}
    commit_message: Prettified Code!
    same_commit: false
    file_pattern: *
    prettier_version: false
    working_directory: false
    only_changed: false
    github_token: ***
Run PATH=$(cd $GITHUB_ACTION_PATH; npm bin):$PATH /home/runner/work/_actions/creyD/prettier_action/v4.2/entrypoint.sh
  PATH=$(cd $GITHUB_ACTION_PATH; npm bin):$PATH /home/runner/work/_actions/creyD/prettier_action/v4.2/entrypoint.sh
  shell: /usr/bin/bash --noprofile --norc -e -o pipefail {0}
  env:
    INPUT_COMMIT_MESSAGE: Prettified Code!
    INPUT_COMMIT_DESCRIPTION: 
    INPUT_SAME_COMMIT: false
    INPUT_COMMIT_OPTIONS: 
    INPUT_FILE_PATTERN: *
    INPUT_PRETTIER_OPTIONS: --check **/*.{js,md}
    INPUT_DRY: true
    INPUT_PRETTIER_VERSION: false
    INPUT_ONLY_CHANGED: false
    INPUT_PRETTIER_PLUGINS: 
    INPUT_WORKING_DIRECTORY: false
    INPUT_GITHUB_TOKEN: ***
Installing prettier...
Prettifying files...
Files:
/home/runner/work/_actions/creyD/prettier_action/v4.2/entrypoint.sh: line 74: prettier: command not found
Problem running prettier with --check **/*.{js,md}
Error: Process completed with exit code 1.

Code of Conduct

Arjun31415 commented 1 year ago

You need to update the github actions for this