Skip to content

Latest commit

 

History

History
41 lines (27 loc) · 1.03 KB

File metadata and controls

41 lines (27 loc) · 1.03 KB

Backend Challenge - Pre-commit Hooks

Introduction

Implement pre-commit hooks for automated code quality and testing checks.

This challenge is tech-agnostic. Choose your preferred programming language, framework, database, ORM, hook management tool, and CI/CD. For middle level, you can use advanced features.

Objectives

  • Set up pre-commit hooks
  • Automate code checks before commits
  • Prevent low-quality code commits

Instructions

  1. Environment Setup:

    • Programming language and web framework
    • Database and ORM
    • Pre-commit hook tool
    • Linting and testing tools
    • Docker (recommended for containerization)
  2. Implementation Details:

    • Configure pre-commit hooks
    • Add checks for linting, formatting, and tests
    • Handle hook failures gracefully
  3. Testing:

    • Attempt commits and verify hook execution

Possible Improvements

  • Add custom hooks
  • Implement selective hook running

Conclusion

By completing this challenge, you will understand commit quality control.

Happy coding!