From 65649e19e7ee7646a880b26c68e07392aef6bbc4 Mon Sep 17 00:00:00 2001 From: TheTechRobo Date: Sat, 10 Sep 2022 12:29:40 -0400 Subject: [PATCH] Add upload-to-transfer --- upload-to-transfer | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 upload-to-transfer diff --git a/upload-to-transfer b/upload-to-transfer new file mode 100644 index 0000000..461d0ed --- /dev/null +++ b/upload-to-transfer @@ -0,0 +1,22 @@ +#!/bin/zsh +# Uploads a file to transfer.archivete.am. +# Usage: upload-to-transfer + +# NEW for the uploaded file! +if [[ -z "$1" ]] then + echo "Usage: $0 [filename]" + echo "If [filename] is not specified, it will default to the filename of the uploaded file." + exit 1 +fi +# WEN + +hi=`basename $1` + +if [[ -z "$2" ]] then + echo hi + 2="$hi" +else + echo bye +fi + +curl --upload-file $1 https://transfer.archivete.am/$2 | less