Skip to content

Commit

Permalink
Implimented prittier into the github action
Browse files Browse the repository at this point in the history
  • Loading branch information
Priyanshu suman authored and Priyanshu suman committed Sep 6, 2024
1 parent a94e051 commit c5581a6
Show file tree
Hide file tree
Showing 5 changed files with 52 additions and 6 deletions.
10 changes: 9 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,4 +87,12 @@ jobs:
if [ -e "server/firebase-secret.json" ] || [ -e ".env" ]; then
echo "Error: Found .env or firebase-secret.json in the pull request. Please remove them before merging."
exit 1
fi
fi

- name: Check Prettier Formatting
run: npm run format:check
working-directory: server/

- name: Check Prettier Formatting
run: npm run format:check
working-directory: client/
16 changes: 16 additions & 0 deletions client/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 7 additions & 4 deletions client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@
"ios": "expo start --ios",
"web": "expo start --web",
"test": "jest --watchAll",
"lint": "expo lint"
"lint": "expo lint",
"format": "prettier --write .",
"format:check": "prettier --check ."
},
"jest": {
"preset": "jest-expo"
Expand Down Expand Up @@ -51,12 +53,13 @@
"@types/jest": "^29.5.12",
"@types/react": "~18.2.45",
"@types/react-test-renderer": "^18.0.7",
"eslint": "^8.57.0",
"eslint-config-expo": "^7.0.0",
"jest": "^29.2.1",
"jest-expo": "~51.0.1",
"prettier": "^3.3.3",
"react-test-renderer": "18.2.0",
"typescript": "~5.3.3",
"eslint": "^8.57.0",
"eslint-config-expo": "^7.0.0"
"typescript": "~5.3.3"
},
"private": true
}
16 changes: 16 additions & 0 deletions server/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@
"start": "node build/index.js",
"build": "npx tsc",
"build:watch": "npx tsc -w",
"start:watch": "nodemon build/index.js"
"start:watch": "nodemon build/index.js",
"format": "prettier --write .",
"format:check": "prettier --check ."
},
"author": "",
"license": "ISC",
Expand All @@ -19,6 +21,7 @@
"@types/jest": "^29.5.11",
"jest": "^29.7.0",
"nodemon": "^3.0.3",
"prettier": "^3.3.3",
"socket.io-client": "^4.7.4",
"ts-node": "^10.9.1",
"typescript": "^5.2.2"
Expand Down

0 comments on commit c5581a6

Please sign in to comment.