---
title: "GIT : Comment renommer une branche locale ?"
canonical: "https://blog.kaptus.net/space/BKAP/blog/167608340/GIT%20%3A%20Comment%20renommer%20une%20branche%20locale%20%3F"
format: markdown
---
## Problème

Comment renommer la branche locale d'un repo git ?

## Solution

<span style="color: #333333">La commande pour renommer une branche locale est la suivante :</span>

```shell
git branch -m <oldname> <newname>
```

<span style="color: #333333">Si l'action concerne la branche courant : </span>

```shell
git branch -m <newname>
```

## Articles connexes



> Macro (contentbylabel)