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

feat: add fetch prune & delete command #205031

Open
wants to merge 14 commits into
base: main
Choose a base branch
from

Conversation

devjiwonchoi
Copy link

@devjiwonchoi devjiwonchoi commented Feb 12, 2024

This PR is port of closed PR #183955

Resolves #183906

@devjiwonchoi devjiwonchoi marked this pull request as ready for review February 12, 2024 19:25
@devjiwonchoi
Copy link
Author

Hey everyone, I’m going to take a look at this PR within a month and add tests and refactor if eligible. Afterwards I’ll try to contact maintainers for review. Thank you for your patience.

@devjiwonchoi
Copy link
Author

devjiwonchoi commented Mar 13, 2024

@lszomoru Sorry to ping you, but respectfully requesting a review. So that you know, this PR and issue #183906 have a sum of 60+ upvotes.

Comment on lines +1763 to +1764
// TODO: origin is hardcoded
.map((el) => el.match(branchRegex)?.[1]?.replace('origin/', '') ?? '')
Copy link
Author

@devjiwonchoi devjiwonchoi Mar 13, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// TODO: origin is hardcoded
.map((el) => el.match(branchRegex)?.[1]?.replace('origin/', '') ?? '')
.map((el) => el.match(branchRegex)?.[1]?.replace('origin/', '') ?? '')

I don't think there will be edge cases for remote origin, or?

Copy link

@prhasn prhasn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@devjiwonchoi
Copy link
Author

Hi @lszomoru, I hope you're doing well! I wanted to check in regarding a PR that's been waiting for your review for a year now. Could you let me know if you're able to take a look in the near future?

@devjiwonchoi
Copy link
Author

@bpasero

Hi, sorry to ping you as this PR been getting much attention from the community, but unfortunately, it hasn't received any feedback for a year now.

I've opened this PR encouraged by #183906 (comment), hope this PR gets any feedback from the team.

@jimmyn
Copy link

jimmyn commented Oct 16, 2024

I am using npx git-removed-branches --prune as an alternative until this feature is implemented.

@lszomoru lszomoru added the git GIT issues label Dec 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
git GIT issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Git - Remove all local branches which origin is deleted (Git Fetch Prune)
5 participants