Skip to content

Commit

Permalink
fix: update husky settings
Browse files Browse the repository at this point in the history
  • Loading branch information
venturalp committed May 21, 2021
1 parent 1382470 commit a5959a9
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 4 deletions.
1 change: 0 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ module.exports = {
},
extends: [
'standard',
'prettier/@typescript-eslint',
'plugin:prettier/recommended',
'eslint:recommended',
'plugin:@typescript-eslint/eslint-recommended',
Expand Down
1 change: 1 addition & 0 deletions .husky/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
_
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npm run lint && npm run cover && npm run build && npm run make-badges && git add 'README.md'
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
| Statements | Branches | Functions | Lines |
| --------------------------------------------------------------------------- | ------------------------------------------------------------------------- | -------------------------------------------------------------------------- | ---------------------------------------------------------------------- |
| ![Statements](https://img.shields.io/badge/Coverage-100%25-brightgreen.svg) | ![Branches](https://img.shields.io/badge/Coverage-100%25-brightgreen.svg) | ![Functions](https://img.shields.io/badge/Coverage-100%25-brightgreen.svg) | ![Lines](https://img.shields.io/badge/Coverage-100%25-brightgreen.svg) |
| ![Statements](https://img.shields.io/badge/Coverage-99.43%25-brightgreen.svg) | ![Branches](https://img.shields.io/badge/Coverage-100%25-brightgreen.svg) | ![Functions](https://img.shields.io/badge/Coverage-97.96%25-brightgreen.svg) | ![Lines](https://img.shields.io/badge/Coverage-99.35%25-brightgreen.svg) |

---

Expand Down
5 changes: 3 additions & 2 deletions src/validate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { hashesConst, readmePathConst, coveragePathConst } from './constants';
import { getCoveragePath, getReadmePath } from './helpers';
import { logger } from './logger';

const { logInfo } = logger();
const { logInfo, logError } = logger();

export const doesReadmeFileExist = (readmePath: string): Promise<boolean | string> => {
return new Promise((resolve, reject) => {
Expand Down Expand Up @@ -69,5 +69,6 @@ export const checkConfig = (): Promise<void> => {
.then(() => {
logInfo('- Readme hashes exist... ✔️.');
})
.then(() => logInfo('Info: 1. Config check process ended'));
.then(() => logInfo('Info: 1. Config check process ended'))
.catch(error => logError(`Info: 1. Config error - ${error}`))
};

0 comments on commit a5959a9

Please sign in to comment.