-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
4,252 additions
and
873 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
node_modules | ||
dist | ||
coverage | ||
.husky | ||
.github |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
{ | ||
"root": true, | ||
"env": { | ||
"node": true, | ||
"jest/globals": true | ||
}, | ||
"parser": "@typescript-eslint/parser", | ||
"plugins": ["@typescript-eslint", "prettier", "jest"], | ||
"extends": ["plugin:@typescript-eslint/recommended", "plugin:@typescript-eslint/recommended-requiring-type-checking", "eslint:recommended"], | ||
"overrides": [ | ||
{ | ||
"files": ["src/**/*.ts"], | ||
"rules": { | ||
"prettier/prettier": "error", | ||
"@typescript-eslint/no-floating-promises": "off", | ||
"@typescript-eslint/no-unsafe-member-access": "off" | ||
} | ||
}, | ||
{ | ||
"files": ["src/**/*.test.ts"], | ||
"plugins": ["jest"], | ||
"extends": ["plugin:jest/recommended"] | ||
} | ||
], | ||
"parserOptions": { | ||
"project": "./tsconfig.json", | ||
"tsconfigRootDir": "." | ||
} | ||
} |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
name: CI/CD | ||
|
||
on: "push" | ||
|
||
jobs: | ||
Tests: | ||
runs-on: ubuntu-latest | ||
name: Run Jest tests | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: '20.x' | ||
- run: npm ci | ||
- run: npm run test | ||
|
||
|
||
deploy: | ||
needs: Tests | ||
runs-on: ubuntu-latest | ||
name: Deploy project | ||
if: github.ref == 'refs/heads/main' | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
|
||
# Describe deployment here | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,8 @@ | ||
node_modules/ | ||
.env | ||
|
||
.vscode | ||
.DS_Store | ||
.eslintcache | ||
coverage | ||
dist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#!/bin/sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
|
||
npx lint-staged |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
### Project Setup | ||
|
||
This project is configured with the following tools and technologies: | ||
|
||
- **TypeScript**: For writing type-safe code. | ||
- **ESLint**: For linting TypeScript code. | ||
- **Prettier**: For code formatting. | ||
- **Husky**: To set up pre-commit hooks. | ||
- **Jest**: For testing code. | ||
|
||
### Usage | ||
|
||
To get started, clone this repository and install the dependencies: | ||
|
||
```bash | ||
git clone https://github.com/volesh/defaultProjectSetup.git | ||
cd defaultProjectSetup | ||
git remote set-url origin <your_repository_URL> | ||
npm install | ||
git push origin <branch-name> | ||
``` | ||
|
||
### Continuous Integration/Continuous Deployment (CI/CD) | ||
|
||
To enable CI/CD, describe the deployment steps in the `.github/workflows/CICD.yml` file. After that, remove the `.github` from the `.gitignore` file and push changes on GitHub. | ||
|
||
|
||
### Husky Hooks | ||
|
||
This project uses Husky to set up pre-commit hooks. It will automatically lint your code before committing. | ||
|
||
|
||
### Contributing | ||
|
||
Contributions are welcome! Please feel free to open issues or pull requests for any improvements or features you'd like to see. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"preset": "ts-jest", | ||
"testEnvironment": "node" | ||
} |
Oops, something went wrong.