Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include git alias to clean up local branches that are no longer on remote #31

Open
1 task
martindsouza opened this issue Aug 18, 2020 · 6 comments
Open
1 task
Assignees
Labels
enhancement New feature or request

Comments

@martindsouza
Copy link
Contributor

A common workflow is to do the following:

Note: all references of "web ui" refers to either Github or Gitlab web sites. Everything listed can also be done using CLI but most people tend to use the web ii

  • (on web ui)
    • Create issue (issue-123)
    • From the issue create a branch (issue-123)
  • (laptop)
    • git pull will get the remote branch
    • Do your work, commit, push to remote branch
  • (on web ui)
    • merge back to master (or other active dev branch)

The problem is that on your laptop branch issue-123 still exists but is not required anymore as it doesn't exists on remote. To date this is a manual cleanup job that can become tedious when lots of issues and branches are created (especially with larger projects). Need ability to quickly and easily remove local branches that no longer exists locally.

Idea:

@martindsouza martindsouza added the enhancement New feature or request label Aug 18, 2020
@martindsouza martindsouza self-assigned this Aug 18, 2020
@martindsouza
Copy link
Contributor Author

@rimblas @neilfernandez any recommendations for alias name for this functionality?

@rimblas
Copy link
Contributor

rimblas commented Aug 20, 2020

Prune?
But I wonder if it would be confused with git remote prune origin

@martindsouza
Copy link
Contributor Author

@rimblas yea want to avoid prune as it'll conflict.

@rimblas
Copy link
Contributor

rimblas commented Aug 20, 2020

In Spanish "podar"? 😬

@rimblas
Copy link
Contributor

rimblas commented Aug 22, 2020

How about one word: prunelocal

@neilfernandez
Copy link

I like that. Some others: “cleanup”, “branchclean”

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants