Skip to end of banner
Go to start of banner

How to use disableHook action in Bitbucket Command Line Interface

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

This article explains how to disable a hook in a Bitbucket repository using Command Line Interface (CLI)

Instructions

  1. Through the disableHook action, a pre-receive or post-receive hook can be disabled from a repository of Bitbucket. 
  2. Refer to the below-given sample action command to disable a hook:

    --action disableHook --project "PROJ" --repository "repo-1" --hook "Reject Force Push"
  3. To check the status of the hook, navigate to Repositories → Repository settings → Hooks. The hook can be disabled as shown in the screenshot below:


It is recommended to test this scenario in a non-production environment or run the action with the --simulate parameter to verify the behavior before deploying.

  • No labels