Using Git Hooks to lint PowerShell
Hi there! 👋 Recently I discovered Git Hooks. Git Hooks provide a way of running custom scripts when a certain git action occurs. In this post, I want to share a pre-commit Git Hook I’ve written to lint PowerShell code using the PSScriptAnalyzer module. What is a Linter? 🕵️♂️ A linter analyses code to identify common errors, bugs and stylistic issues. Their aim is to improve code quality. Linters perform static analysis meaning they check code without executing it. Some well known linters for other languages include ESLint and Pylint. ...