From 454395f85cdf3a9bf0d527275f79990692b284c6 Mon Sep 17 00:00:00 2001 From: DevAndromeda <46562212+DevAndromeda@users.noreply.github.com> Date: Thu, 5 Aug 2021 14:30:02 +0545 Subject: [PATCH] chore: setup husky --- .husky/pre-commit | 4 ++++ package.json | 1 + yarn.lock | 5 +++++ 3 files changed, 10 insertions(+) create mode 100644 .husky/pre-commit diff --git a/.husky/pre-commit b/.husky/pre-commit new file mode 100644 index 0000000..517826d --- /dev/null +++ b/.husky/pre-commit @@ -0,0 +1,4 @@ +#!/bin/sh +. "$(dirname "$0")/_/husky.sh" + +npm run format && npm run lint:fix \ No newline at end of file diff --git a/package.json b/package.json index a11cc41..4cb9a13 100644 --- a/package.json +++ b/package.json @@ -76,6 +76,7 @@ "discord-api-types": "^0.22.0", "discord.js": "^13.0.0-dev.t1628124537.3eb4140", "eslint": "^7.32.0", + "husky": "^7.0.1", "jsdoc-babel": "^0.5.0", "prettier": "^2.3.2", "rimraf": "^3.0.2", diff --git a/yarn.lock b/yarn.lock index d4cadab..2b47ed5 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2992,6 +2992,11 @@ https-proxy-agent@^5.0.0: agent-base "6" debug "4" +husky@^7.0.1: + version "7.0.1" + resolved "https://registry.yarnpkg.com/husky/-/husky-7.0.1.tgz#579f4180b5da4520263e8713cc832942b48e1f1c" + integrity sha512-gceRaITVZ+cJH9sNHqx5tFwbzlLCVxtVZcusME8JYQ8Edy5mpGDOqD8QBCdMhpyo9a+JXddnujQ4rpY2Ff9SJA== + iconv-lite@0.4.24, iconv-lite@^0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b"