Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Good afternoon!
Can I use a pipeline to prevent a commit from being made or something specific, for example in bitbucket cloud there is no validation for tags, so for example I want to prevent commits on a tag, to leave it immutable or even prevent its deletion, we know that git has a feature called git hook, can I implement this within the pipeline so that it blocks any commit before interacting with the repository?

1 answer

0 votes
Syahrul
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Oct 29, 2023

Hey @Joao Pedro Correia 

I'm not getting your goals here, so I would appreciate it if you could give more context.

That said, in Bitbucket cloud, you can't directly use a pipeline to prevent a commit from being made or enforce Git hooks to block commits at the server level. Bitbucket cloud doesn't provide server-level Git hook capabilities like some other Git hosting services do.

You can take some alternative approaches to achieve similar outcomes using the following features:

I hope this helps.

Regards,
Syahrul

https://confluence.atlassian.com/bitbucketserver/using-repository-hooks-776639836.html#Usingrepositoryhooks-Defaultpre-receivehooks


I would like something like a pre-recive that analyzes before entering the cloud, similar to the link above, but I haven't found this functionality.

Is it possible to use branch restrictions on TAGs, such as stopping the name, being immutable, not allowing deletion?

Syahrul
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Oct 30, 2023

Hi @Joao Pedro Correia 

It's not possible to use git hook in Bitbucket cloud or tags restriction. We do have an existing feature request on this at:

Regards,
Syahrul

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events