Creating Orphan branches in Bitbucket

How we can create an empty branch in bitbucket using git command?


git checkout --orphan <orphan-branch-name>

git rm -rf .

git commit --allow-empty -m “Empty branch”

git push origin <orphan-branch-name>

Comments

Popular posts from this blog

SwiftUI - Tutorial 2 - 🧵 Understanding @MainActor in SwiftUI — A Beginner’s Guide

SonarQube With Angular 19 on Windows: A Complete Setup and Integration Guide

Setting Up Jenkins for Flutter App on macOS