observablehq / feedback

Customer submitted bugs and feature requests
42 stars 3 forks source link

option to delete a fork on merge #498

Open trebor opened 1 year ago

trebor commented 1 year ago

Is your feature request related to a problem? Please describe.

it can be pretty hard to keep track of all my forks, and often they need to exist only until merged.

Describe the solution you'd like

at the moment of merge, offer an option to Merge & Delete the fork. the fork will only wind up in the trash, so it's not all that risky. when done navigate the user back to the parent notebook.

Describe alternatives you've considered

belt and suspenders: perhaps only offer a delete option if merge will result in two identical notebooks.

Martien commented 1 year ago

How can I vote this up?

mbostock commented 1 year ago

How can I vote this up?

Click the smiley face on the top comment:

Screen Shot 2022-11-11 at 3 19 49 PM

Then click the 👍 .

CobusT commented 1 year ago

Just to refine this a bit, we could only surface this option when the user has edit permissions on the fork. Another way to think about this is whether the suggester should make this choice, rather than the person merging? That way the control belongs to the owner of the suggestion...

Martien commented 1 year ago

How can I vote this up?

Click the smiley face on the top comment: Then click the 👍.

Ah, thanks. I used the browser rather than the github app. There is no :-) in the browser view :-(.

Martien commented 1 year ago

BTW, seems like a lucky coincident, as I just wrote up my workflow the other day.

https://observablehq.com/@martien/observable-workflow

I like the ‘always public` intention of Observable notebooks, yet still need a private area (lab, studio, atelier) to tinker and mess with it.

mootari commented 1 year ago

Just to refine this a bit, we could only surface this option when the user has edit permissions on the fork. Another way to think about this is whether the suggester should make this choice, rather than the person merging? That way the control belongs to the owner of the suggestion...

@CobusT I'd welcome having this option for all suggestions, because it reduces the mental bookkeeping after a suggestion was made (I don't have to remember to go in and delete the notebook). I can always recover the notebook from thrash.

However, a considerable downside might be that the author of the parent might want to leave a comment on the suggestion after merging. We'd want to make sure that they're aware that merging will also delete the suggestion.

The way it's done in GitLab is that a PR author can set a default behavior for the PR. The merging party can then still opt to keep the branch instead of deleting it.

Edit I misremembered, GitLab just displays a notification if you don't have write access to the branch:

image

_(Source: Deleting the source branch)_