Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This article explains how to delete a group in Bitbucket using Command Line Interface (CLI).

Instructions

  1. Using Use removeGroup allows deleting  to delete a group from Bitbucket from the Bitbucket instance.

    Code Block
    themeMidnight
    --action removeGroup --group "testgroup"


  2. The To retain the users in the group to be deleted can be moved , move them to to another group by mentioning the new group name in using the --defaultGroup optional parameter.

    Code Block
    themeMidnight
    --action removeGroup --group "testgroup" --defaultGroup "jira-administrators"

    With the above this command, all the users inside the within testgroup will be are moved to to the jira-administrators group and then the testgroup will be is deleted.

    In above CLI action, 

    • --group value refers to Group name  value refers to group name.
    • --defaultGroup value refers to Default to default group to move users.
Info

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