Skip to content

Rename a branch on the github.com web UI #2500

Closed

Description

@staabm

when working on github we get all kind of automation which creates branches and works on our repo.

since I dont own most of this automation I have no influence on the naming of the branches.

e.g. Dependabot creates branch names like dependabot-npm_and_yarn-simplebar-5.0.3 which contains . characters, which are a problem for our further processing.

would it be possible to add a feature to refined github, so we will be able to rename a branch on github.com directly, without the need of a clone/fork and the git cli commands etc...?

Activity

  1. changed the title [-]rename a branch on github[/-] [+]rename a branch on the github.com web UI[/+] on Oct 23, 2019
  2. sindresorhus commented on Oct 27, 2019

    @sindresorhus
    Member

    Please also send this feature request to GitHub: [email protected]

  3. changed the title [-]rename a branch on the github.com web UI[/-] [+]Rename a branch on the github.com web UI[/+] on Oct 27, 2019
  4. staabm commented on Oct 27, 2019

    @staabm
    Author

    Done

  5. fregante commented on Jan 29, 2020

    @fregante
    Member

    This is already possible on GitHub, however it requires several steps:

    1. Visit branch
    2. Create branch from the branch selector:

    branch selector

    1. Visit "Branches" page again
    2. Delete the previous branch

    PR welcome to add a button next to delete:

    1. ask for name via window.prompt()
    2. call API to create a branch
    3. "click" delete button
    4. Trigger UI update
  6. added
    small
    and removed on Jan 29, 2020
  7. fregante commented on Mar 15, 2020

    @fregante
    Member

    Renaming isn’t a safe operation, any PRs open on that branch will be disconnected, not transferred as one would expect.

    I’d prefer #2895 instead. One more click (“Delete”), but less broken expectations.

  8. added and removed
    small
    on Mar 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions