diff --git a/package.json b/package.json index 0290d0ee..a30c8482 100644 --- a/package.json +++ b/package.json @@ -38,6 +38,7 @@ "lerna": "2.0.0", "mkdirp": "0.5.1", "npm-run-all": "4.0.2", + "pre-commit": "1.2.2", "rimraf": "2.6.1", "standard-version": "4.2.0", "stylelint": "7.13.0", @@ -48,8 +49,13 @@ "typescript": "2.5.2", "webpack": "2.4.1" }, + "pre-commit": [ + "precommit-msg", + "lint" + ], "scripts": { "postinstall": "lerna bootstrap", + "precommit-msg": "Git precommit hook is running... & exit 0", "test": "run-p -sn test:test-serializer test:uhk-common", "test:test-serializer": "lerna exec --scope test-serializer npm test", "test:uhk-common": "lerna exec --scope uhk-common npm test", diff --git a/packages/uhk-common/src/config-serializer/config-items/user-configuration.ts b/packages/uhk-common/src/config-serializer/config-items/user-configuration.ts index 37aa0a0b..46299611 100644 --- a/packages/uhk-common/src/config-serializer/config-items/user-configuration.ts +++ b/packages/uhk-common/src/config-serializer/config-items/user-configuration.ts @@ -100,7 +100,7 @@ export class UserConfiguration { return this.macros.find(macro => macroId === macro.id); } - recalculateConfigurationLength(){ + recalculateConfigurationLength() { const buffer = new UhkBuffer(); this.toBinary(buffer); this.userConfigurationLength = buffer.offset;