question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`quick-repo-deletion` activating by default seems overly aggressive

See original GitHub issue

It appears that #3795 enabled the quick-repo-deletion button for all repositories - the PR title and linked issue reference enabling the feature for “empty” repositories, but it appears that the feature code actually defines empty as “has not been starred”:

https://github.com/sindresorhus/refined-github/blob/eb79224b4dbf0852651c42cca2ff770ae185d100/source/features/quick-repo-deletion.tsx#L111-L119

This means that the delete button appears for all private repositories, especially organization repos, where users are unlikely to star an internal company repo. It would also appear for any personal repositories that haven’t been starred, regardless of how many commits said repo has (like, you can have 100s of commits in a repo, and if nobody has starred it, this button still appears).

This doesn’t seem like intended behavior. Having a very prominent Delete button for any repo that has no stars isn’t quite the same as making it easy to clean up empty repositories.

Would it be possible to change the activation criteria? Perhaps it could take into account whether or not the repo actually contained commits (is it really empty, especially if it’s not a fork), or whether it was a private repo. Or perhaps there’s a better criteria all together for the intent of this feature. There’s probably a narrower range of repos where having a featured delete button makes UX sense.


tl;dr - seeing a red DELETE button at the top of all our company repos is slightly concerning 😅

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:10
  • Comments:8 (7 by maintainers)

github_iconTop GitHub Comments

3reactions
fregantecommented, Dec 27, 2020

I released a new version/hotfix that includes the above change.

3reactions
FloEdelmanncommented, Dec 20, 2020

Also maybe it should be added to the more drop down?

I think that should be exclusively for navigation, not actions.

Having the button on the settings page is also an option, but the loading adds some annoying delay that could be avoided.

How often would one experience this delay? Only once per repository. I think having to dig into the settings is fine (for non-fork repositories).

Read more comments on GitHub >

github_iconTop Results From Across the Web

quick-repo-deletion activating by default seems overly ...
It appears that #3795 enabled the quick-repo-deletion button for all repositories - the PR title and linked issue reference enabling the ...
Read more >
sindresorhus/refined-github (Raised $2,687.94) - Issuehunt
Default branch button shows on default branch in private repo ... `quick-repo-deletion` activating by default seems overly aggressive.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found