5

GitHub has nice feature that you can attach files to issue comments.

But is there any way to undo attaching unwanted file?

Even if comment is never submitted the file stays there forever, see for example https://user-images.githubusercontent.com/899988/146889867-edb59e9a-5709-4c17-b6d5-b0c863bc5f9e.png

It is even worse with .ods files where randomly generated part is much shorter.

How can I trigger deletion of such accidentally uploaded files if I have link to them?

1
  • 1
    Even worse, if you paste into a file in a private repository, the generated image link is publicly accessible!
    – daviewales
    Oct 26, 2022 at 3:59

2 Answers 2

6

If you're the uploader of the image, which has an URL in this format https://user-images.githubusercontent.com/123456/123456789-abcdefgh-1234-abcd-1234-1234abcd5678.png, you can now make use of the virtual agent to remove the image: https://support.github.com/?q=remove+image+attachment

Click on the button "Remove uploaded images with our Virtual Agent".

Remove uploaded images with GitHub Virtual Agent

If you're trying to delete an uploaded file with an URL in this format https://github.com/github/linguist/files/1/example.docx, use this link instead: https://support.github.com/?q=remove+file+attachment

The deletion is not instant, but took less than a day.

2
1

It appears that contacting support is the only viable chance to fix such issues ( https://support.github.com/contact ).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.