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

Your build is currently configured to use incompatible Java 21.0.3 and Gradle 8.2.1. Cannot sync the project.

Error in Android Migration Gradle 7.5 to 8.5 - java.lang.NullPointerException: Cannot invoke "String.length()" because "" is null

What is an android Activity,AppCompatActivity and Fragment Activity. Interview Question