mirror of
https://github.com/dutchcoders/transfer.sh.git
synced 2026-02-03 14:13:26 +00:00
how can delete a my file with curl #99
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @thebardockgames on GitHub.
@bahammut commented on GitHub:
and if we upload without run this grep part, how to delete the file without this specific header value !?
@paolafrancesca commented on GitHub:
@bahammut there's no way without knowing the delete token
if you uploaded on transfer.sh you can try asking @stefanbenten
@toastie89 commented on GitHub:
Hi, the procedure described below works for me:
https://github.com/dutchcoders/transfer.sh#x-url-delete
https://github.com/dutchcoders/transfer.sh#deleting
Where do you stuck?
@stefanbenten commented on GitHub:
You can always reach out via the contact-us form on the website and we'll be happy to help with getting files deleted, if proven ownership of the file exists 👍
@reorx commented on GitHub:
It's very easy to forget to grep the file because grep is not included in the getting started command.
Would it be a good idea to show the deleted url in upload response? Like:
@reorx commented on GitHub:
You are right, there must be many scripts that relies on the output to
parse the download url.
My suggestion to document is to add a
-vafter curl, making the commandlooks like below:
curl -v —upload-file hello https://transfer.sh/hello.txt
On Mon, Sep 19, 2022 at 13:27 Andrea Spacca @.***>
wrote:
--
Xiao Meng
@paolafrancesca commented on GitHub:
@Dan1jel , @reorx
you might want to give a look at the sample bash/zsh function on the readme https://github.com/dutchcoders/transfer.sh#bash-and-zsh-with-delete-url-delete-token-output-and-prompt-before-uploading :)
@Dan1jel if it doesn't not work for fish and you are able to improve, you're welcome to open a PR :)
@paolafrancesca commented on GitHub:
@reorx unluckily change the output of the command will be a breaking change that we are not willing to do
maybe we can improve te documentation in the getting started command: any suggestion is welcome
@Dan1jel commented on GitHub:
I have for a while trying to figure out the delete token.
Is there a way to show regular and delete token in one curl command?
When i use
curl -sD - --upload-file test.txt https://transfer.sh/test.txt | grep "x-delete-token"i only the delete token in a whole link. But i would like to have one url and one line with token only.Sorry but I'm new to the whole curl and grep thing.
UPDATE: ended up with this in my fish shell function
this is what i use in termux function so i can copy to clipboard but also see the url and delete token in the teminal -
and this is for use on my linux computer (i have this as a IF function all togather).
if someone was intrested on how i did it. Please give feedback is something is off or could have done better.
@Dan1jel commented on GitHub:
Did not see that, thanks for the tip, dont know if i would be able to do better tho, my thought was to make an zip to upload instead of several files, thats why my line is small and minimalist but yea, that sample was really nice :)