---
title: "How to disable githooks in an Azure DevOps YAML Pipeline"
url: https://daily.dev/posts/how-to-disable-githooks-in-an-azure-devops-yaml-pipeline-lz4vxjnev
source_url: https://timdeschryver.dev/blog/how-to-disable-githooks-in-an-azure-devops-yaml-pipeline
type: article
source: "Tim Deschryver"
author: "Tim Deschryver"
published: 2026-05-31T07:47:02.601Z
updated: 2026-06-01T04:00:38.412Z
tags: ["cicd", "git", "azure-devops"]
reading_time: 3
upvotes: 0
comments: 0
language: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# How to disable githooks in an Azure DevOps YAML Pipeline

**[Tim Deschryver](https://daily.dev/sources/timdeschryver)** · [@timdeschryver](https://daily.dev/timdeschryver) · 3 min read · 0 upvotes · 0 comments

## Summary

Azure DevOps pipelines do not set the CI environment variable by default, which can cause git hooks (like post-checkout hooks managed by Husky) to run unexpectedly and break the pipeline. The fix is to explicitly set CI=true in the YAML pipeline's variables section, which signals to the hook scripts that they should skip execution in a CI context.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://timdeschryver.dev/blog/how-to-disable-githooks-in-an-azure-devops-yaml-pipeline>

## Similar posts on daily.dev

- [Why my Azure DevOps scheduled pipeline never ran](https://daily.dev/posts/why-my-azure-devops-scheduled-pipeline-never-ran-5s2h7tnhs) · The Art of Simplicity · 1 upvotes · 0 comments
- [Azure Pipelines–Failed to set a git tag](https://daily.dev/posts/azure-pipelines-failed-to-set-a-git-tag-w60x9wgtv) · The Art of Simplicity · 1 upvotes · 0 comments
- [Minimal Git CI using hooks](https://daily.dev/posts/minimal-git-ci-using-hooks-z5xuuof5r) · Lobsters · 0 upvotes · 0 comments

---

Tags: [#cicd](https://daily.dev/tags/cicd), [#git](https://daily.dev/tags/git), [#azure-devops](https://daily.dev/tags/azure-devops)

[View this post on daily.dev](https://daily.dev/posts/how-to-disable-githooks-in-an-azure-devops-yaml-pipeline-lz4vxjnev)
