[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-4875":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":17,"stars7d":17,"stars30d":18,"stars90d":16,"forks30d":16,"starsTrendScore":19,"compositeScore":20,"rankGlobal":10,"rankLanguage":10,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":24,"hasPages":22,"topics":25,"createdAt":10,"pushedAt":10,"updatedAt":33,"readmeContent":34,"aiSummary":35,"trendingCount":16,"starSnapshotCount":16,"syncStatus":36,"lastSyncTime":37,"discoverSource":38},4875,"transfer.sh","dutchcoders\u002Ftransfer.sh","dutchcoders","Easy and fast file sharing from the command-line.","https:\u002F\u002Fgithub.com\u002Fdutchcoders\u002Ftransfer.sh",null,"Go",15848,1581,202,48,0,1,19,3,44.6,"MIT License",false,"main",true,[26,27,28,29,30,31,32],"docker","golang","hacktoberfest","hacktoberfest2021","share","transfer","transfersh","2026-06-12 02:01:05","# transfer.sh [![Go Report Card](https:\u002F\u002Fgoreportcard.com\u002Fbadge\u002Fgithub.com\u002Fdutchcoders\u002Ftransfer.sh)](https:\u002F\u002Fgoreportcard.com\u002Freport\u002Fgithub.com\u002Fdutchcoders\u002Ftransfer.sh) [![Docker pulls](https:\u002F\u002Fimg.shields.io\u002Fdocker\u002Fpulls\u002Fdutchcoders\u002Ftransfer.sh.svg)](https:\u002F\u002Fhub.docker.com\u002Fr\u002Fdutchcoders\u002Ftransfer.sh\u002F) [![Build Status](https:\u002F\u002Fgithub.com\u002Fdutchcoders\u002Ftransfer.sh\u002Factions\u002Fworkflows\u002Ftest.yml\u002Fbadge.svg?branch=main)](https:\u002F\u002Fgithub.com\u002Fdutchcoders\u002Ftransfer.sh\u002Factions\u002Fworkflows\u002Ftest.yml?query=branch%3Amain)\n\nEasy and fast file sharing from the command-line. This code contains the server with everything you need to create your own instance.\n\nTransfer.sh currently supports the s3 (Amazon S3), gdrive (Google Drive), storj (Storj) providers, and local file system (local).\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Disclaimer\n\n@stefanbenten happens to be a maintainer of this repository _and_ the person who host a well known public installation of the software in the repo.\n\nThe two are anyway unrelated, and the repo is not the place to direct requests and issues for any of the pubblic installation.\n\nNo third-party public installation of the software in the repo will be advertised or mentioned in the repo itself, for security reasons.\n\nThe official position of me, @aspacca, as maintainer of the repo, is that if you want to use the software you should host your own installation.\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Usage\n\nThis section outlines how to use transfer.sh\n\n\u003Cbr \u002F>\n\n### Upload\n\n```bash\n$ curl -v --upload-file .\u002Fhello.txt https:\u002F\u002Ftransfer.sh\u002Fhello.txt\n```\n\n\u003Cbr \u002F>\n\n### Encrypt & Upload\n\n```bash\n$ gpg --armor --symmetric --output - \u002Ftmp\u002Fhello.txt | curl --upload-file - https:\u002F\u002Ftransfer.sh\u002Ftest.txt\n```\n\n\u003Cbr \u002F>\n\n### Download & Decrypt\n\n```bash\n$ curl https:\u002F\u002Ftransfer.sh\u002F1lDau\u002Ftest.txt | gpg --decrypt --output \u002Ftmp\u002Fhello.txt\n```\n\n\u003Cbr \u002F>\n\n### Upload to Virustotal\n\n```bash\n$ curl -X PUT --upload-file nhgbhhj https:\u002F\u002Ftransfer.sh\u002Ftest.txt\u002Fvirustotal\n```\n\n\u003Cbr \u002F>\n\n### Deleting\n\n```bash\n$ curl -X DELETE \u003CX-Url-Delete Response Header URL>\n```\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Request Headers\n\nThis section explains how to handle request headers with curl:\n\n\u003Cbr \u002F>\n\n### Max-Downloads\n\n```bash\n$ curl --upload-file .\u002Fhello.txt https:\u002F\u002Ftransfer.sh\u002Fhello.txt -H \"Max-Downloads: 1\" # Limit the number of downloads\n```\n\n\u003Cbr \u002F>\n\n### Max-Days\n\n```bash\n$ curl --upload-file .\u002Fhello.txt https:\u002F\u002Ftransfer.sh\u002Fhello.txt -H \"Max-Days: 1\" # Set the number of days before deletion\n```\n\n\u003Cbr \u002F>\n\n### X-Encrypt-Password\n\n#### Beware, use this feature only on your self-hosted server: trusting a third-party service for server side encryption is at your own risk\n```bash\n$ curl --upload-file .\u002Fhello.txt https:\u002F\u002Fyour-transfersh-instance.tld\u002Fhello.txt -H \"X-Encrypt-Password: test\" # Encrypt the content server side with AES256 using \"test\" as password\n```\n\n\u003Cbr \u002F>\n\n### X-Decrypt-Password\n#### Beware, use this feature only on your self-hosted server: trusting a third-party service for server side encryption is at your own risk\n\n```bash\n$ curl https:\u002F\u002Fyour-transfersh-instance.tld\u002FBAYh0\u002Fhello.txt -H \"X-Decrypt-Password: test\" # Decrypt the content server side with AES256 using \"test\" as password\n```\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Response Headers\n\nThis section explains how to handle response headers:\n\n\u003Cbr \u002F>\n\n### X-Url-Delete\n\nThe URL used to request the deletion of a file and returned as a response header:\n\n```bash\ncurl -sD - --upload-file .\u002Fhello.txt https:\u002F\u002Ftransfer.sh\u002Fhello.txt | grep -i -E 'transfer\\.sh|x-url-delete'\nx-url-delete: https:\u002F\u002Ftransfer.sh\u002Fhello.txt\u002FBAYh0\u002Fhello.txt\u002FPDw0NHPcqU\nhttps:\u002F\u002Ftransfer.sh\u002Fhello.txt\u002FBAYh0\u002Fhello.txt\n```\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Examples\n\nSee good usage examples on [examples.md](examples.md)\n\n\u003Cbr \u002F>\n\n## Link aliases\n\nCreate direct download link:\n\nhttps:\u002F\u002Ftransfer.sh\u002F1lDau\u002Ftest.txt --> https:\u002F\u002Ftransfer.sh\u002Fget\u002F1lDau\u002Ftest.txt\n\nInline file:\n\nhttps:\u002F\u002Ftransfer.sh\u002F1lDau\u002Ftest.txt --> https:\u002F\u002Ftransfer.sh\u002Finline\u002F1lDau\u002Ftest.txt\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Usage\n\nParameter | Description                                                                             | Value                         | Env                         \n--- |-----------------------------------------------------------------------------------------------|-------------------------------|-------------------------------|\nlistener | port to use for http (:80)                                                               |                               | LISTENER                      |\nprofile-listener | port to use for profiler (:6060)                                                 |                               | PROFILE_LISTENER              |\nforce-https | redirect to https                                                                     | false                         | FORCE_HTTPS                   |\ntls-listener | port to use for https (:443)                                                         |                               | TLS_LISTENER                  |\ntls-listener-only | flag to enable tls listener only                                                |                               | TLS_LISTENER_ONLY             |\ntls-cert-file | path to tls certificate                                                             |                               | TLS_CERT_FILE                 |\ntls-private-key | path to tls private key                                                           |                               | TLS_PRIVATE_KEY               |\nhttp-auth-user | user for basic http auth on upload                                                 |                               | HTTP_AUTH_USER                |\nhttp-auth-pass | pass for basic http auth on upload                                                 |                               | HTTP_AUTH_PASS                |\nhttp-auth-htpasswd | htpasswd file path for basic http auth on upload                               |                               | HTTP_AUTH_HTPASSWD            |\nhttp-auth-ip-whitelist | comma separated list of allowed ips to upload without auth challenge       |                               | HTTP_AUTH_IP_WHITELIST        |\nvirustotal-key | VirusTotal API key                                                                 |                               | VIRUSTOTAL_KEY                |\nip-whitelist | comma separated list of ips allowed to connect to the service                        |                               | IP_WHITELIST                  |\nip-blacklist | comma separated list of ips not allowed to connect to the service                    |                               | IP_BLACKLIST                  |\ntemp-path | path to temp folder                                                                     | system temp                   | TEMP_PATH                     |\nweb-path | path to static web files (for development or custom front end)                           |                               | WEB_PATH                      |\nproxy-path | path prefix when service is run behind a proxy (a `\u002F` prefix will be trimmed)          |                               | PROXY_PATH                    |\nproxy-port | port of the proxy when the service is run behind a proxy                               |                               | PROXY_PORT                    |\nemail-contact | email contact for the front end                                                     |                               | EMAIL_CONTACT                 |\nga-key | google analytics key for the front end                                                     |                               | GA_KEY                        |\nprovider | which storage provider to use                                                            | (s3, storj, gdrive or local)  |                               |\nuservoice-key | user voice key for the front end                                                    |                               | USERVOICE_KEY                 |\naws-access-key | aws access key                                                                     |                               | AWS_ACCESS_KEY                |\naws-secret-key | aws access key                                                                     |                               | AWS_SECRET_KEY                |\nbucket | aws bucket                                                                                 |                               | BUCKET                        |\ns3-endpoint | Custom S3 endpoint.                                                                   |                               | S3_ENDPOINT                   |\ns3-region | region of the s3 bucket                                                                 | eu-west-1                     | S3_REGION                     |\ns3-no-multipart | disables s3 multipart upload                                                      | false                         | S3_NO_MULTIPART               |\ns3-path-style | Forces path style URLs, required for Minio.                                         | false                         | S3_PATH_STYLE                 |\nstorj-access | Access for the project                                                               |                               | STORJ_ACCESS                  |\nstorj-bucket | Bucket to use within the project                                                     |                               | STORJ_BUCKET                  |\nbasedir | path storage for local\u002Fgdrive provider                                                    |                               | BASEDIR                       |\ngdrive-client-json-filepath | path to oauth client json config for gdrive provider                  |                               | GDRIVE_CLIENT_JSON_FILEPATH   |\ngdrive-local-config-path | path to store local transfer.sh config cache for gdrive provider         |                               | GDRIVE_LOCAL_CONFIG_PATH      |\ngdrive-chunk-size | chunk size for gdrive upload in megabytes, must be lower than available memory (8 MB) |                         | GDRIVE_CHUNK_SIZE             |\nlets-encrypt-hosts | hosts to use for lets encrypt certificates (comma separated)                   |                               | HOSTS                         |\nlog | path to log file                                                                              |                               | LOG                           |\ncors-domains | comma separated list of domains for CORS, setting it enable CORS                     |                               | CORS_DOMAINS                  |\nclamav-host | host for clamav feature                                                               |                               | CLAMAV_HOST                   |\nperform-clamav-prescan | prescan every upload using clamav (clamav-host must be local clamd unix socket)    |                       | PERFORM_CLAMAV_PRESCAN        |\nrate-limit | request per minute                                                                     |                               | RATE_LIMIT                    |\nmax-upload-size | max upload size in kilobytes                                                      |                               | MAX_UPLOAD_SIZE               |\npurge-days | number of days after the uploads are purged automatically                              |                               | PURGE_DAYS                    |   \npurge-interval | interval (hours) to run automatic purge for (excluding S3 and Storj)               |                               | PURGE_INTERVAL                |   \nrandom-token-length | length of random token for upload path (double the size for delete path)      | 6                             | RANDOM_TOKEN_LENGTH           |   \n\nIf you want to use TLS using lets encrypt certificates, set lets-encrypt-hosts to your domain, set tls-listener to :443 and enable force-https.\n\nIf you want to use TLS using your own certificates, set tls-listener to :443, force-https, tls-cert-file and tls-private-key.\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Development\n\nSwitched to GO111MODULE\n\n```bash\ngo run main.go --provider=local --listener :8080 --temp-path=\u002Ftmp\u002F --basedir=\u002Ftmp\u002F\n```\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Build\n\n```bash\n$ git clone git@github.com:dutchcoders\u002Ftransfer.sh.git\n$ cd transfer.sh\n$ go build -o transfersh main.go\n```\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Docker\n\nFor easy deployment, we've created an official Docker container. There are two variants, differing only by which user runs the process.\n\nThe default one will run as `root`:\n\n> [!WARNING]\n> It is discouraged to use `latest` tag for WatchTower or similar tools. The `latest` tag can reference unreleased developer, test builds, and patch releases for older versions. Use an actual version tag until transfer.sh supports major or minor version tags.\n\n```bash\ndocker run --publish 8080:8080 dutchcoders\u002Ftransfer.sh:latest --provider local --basedir \u002Ftmp\u002F\n```\n\n\u003Cbr \u002F>\n\n### No root\n\nThe `-noroot` tags indicate image builds that run with least priviledge to reduce the attack surface might an application get compromised.\n\n> [!NOTE]\n> Using `-noroot` is **recommended**\n\n\u003Cbr \u002F>\n\nThe one tagged with the suffix `-noroot` will use `5000` as both UID and GID:\n\n```bash\ndocker run --publish 8080:8080 dutchcoders\u002Ftransfer.sh:latest-noroot --provider local --basedir \u002Ftmp\u002F\n```\n\n\u003Cbr \u002F>\n\n> [!NOTE]\n> Development history details at:\n> - https:\u002F\u002Fgithub.com\u002Fdutchcoders\u002Ftransfer.sh\u002Fpull\u002F418\n\n\u003Cbr \u002F>\n\n### Tags\n\nName | Usage\n--|--\nlatest| Latest CI build, can be nightly, at commit, at tag, etc.\nlatest-noroot| Latest CI build, can be nightly, at commit, at tag, etc. using [no root]\nnightly| Scheduled CI build every midnight UTC\nnightly-noroot| Scheduled CI build every midnight UTC using [no root]\nedge| Latest CI build after every commit on `main`\nedge-noroot| Latest CI build after every commit on `main` using [no root]\nv`x.y.z`| CI build after tagging a release\nv`x.y.z`-noroot| CI build after tagging a release using [no root]\n\n\u003Cbr \u002F>\n\n### Building the Container\n\nYou can also build the container yourself. This allows you to choose which UID\u002FGID will be used, e.g. when using NFS mounts:\n\n```bash\n# Build arguments:\n# * RUNAS: If empty, the container will run as root.\n#          Set this to anything to enable UID\u002FGID selection.\n# * PUID:  UID of the process. Needs RUNAS != \"\". Defaults to 5000.\n# * PGID:  GID of the process. Needs RUNAS != \"\". Defaults to 5000.\n\ndocker build -t transfer.sh-noroot --build-arg RUNAS=doesntmatter --build-arg PUID=1337 --build-arg PGID=1338 .\n```\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## S3 Usage\n\nFor the usage with a AWS S3 Bucket, you just need to specify the following options:\n- provider `--provider s3`\n- aws-access-key _(either via flag or environment variable `AWS_ACCESS_KEY`)_\n- aws-secret-key _(either via flag or environment variable `AWS_SECRET_KEY`)_\n- bucket _(either via flag or environment variable `BUCKET`)_\n- s3-region _(either via flag or environment variable `S3_REGION`)_\n\nIf you specify the s3-region, you don't need to set the endpoint URL since the correct endpoint will used automatically.\n\n\u003Cbr \u002F>\n\n### Custom S3 providers\n\nTo use a custom non-AWS S3 provider, you need to specify the endpoint as defined from your cloud provider.\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Storj Network Provider\n\nTo use the Storj Network as a storage provider you need to specify the following flags:\n- provider `--provider storj`\n- storj-access _(either via flag or environment variable STORJ_ACCESS)_\n- storj-bucket _(either via flag or environment variable STORJ_BUCKET)_\n\n\u003Cbr \u002F>\n\n### Creating Bucket and Scope\n\nYou need to create an access grant (or copy it from the uplink configuration) and a bucket in preparation.\n\nTo get started, log in to your account and go to the Access Grant Menu and start the Wizard on the upper right.\n\nEnter your access grant name of choice, hit *Next* and restrict it as necessary\u002Fpreferred.\nAfterwards continue either in CLI or within the Browser. Next, you'll be asked for a Passphrase used as Encryption Key.\n**Make sure to save it in a safe place. Without it, you will lose the ability to decrypt your files!**\n\nAfterwards, you can copy the access grant and then start the startup of the transfer.sh endpoint. \nIt is recommended to provide both the access grant and the bucket name as ENV Variables for enhanced security.\n\nExample:\n\n```\nexport STORJ_BUCKET=\u003CBUCKET NAME>\nexport STORJ_ACCESS=\u003CACCESS GRANT>\ntransfer.sh --provider storj\n```\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Google Drive Usage\n\nFor the usage with Google drive, you need to specify the following options:\n- provider\n- gdrive-client-json-filepath\n- gdrive-local-config-path\n- basedir\n\n\u003Cbr \u002F>\n\n### Creating Gdrive Client Json\n\nYou need to create an OAuth Client id from console.cloud.google.com, download the file, and place it into a safe directory.\n\n\u003Cbr \u002F>\n\n### Usage example\n\n```go run main.go --provider gdrive --basedir \u002Ftmp\u002F --gdrive-client-json-filepath \u002F[credential_dir] --gdrive-local-config-path [directory_to_save_config] ```\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Shell functions\n\n### Bash, ash and zsh (multiple files uploaded as zip archive)\n##### Add this to .bashrc or .zshrc or its equivalent\n```bash\ntransfer() (if [ $# -eq 0 ]; then printf \"No arguments specified.\\nUsage:\\n transfer \u003Cfile|directory>\\n ... | transfer \u003Cfile_name>\\n\">&2; return 1; fi; file_name=$(basename \"$1\"); if [ -t 0 ]; then file=\"$1\"; if [ ! -e \"$file\" ]; then echo \"$file: No such file or directory\">&2; return 1; fi; if [ -d \"$file\" ]; then cd \"$file\" || return 1; file_name=\"$file_name.zip\"; set -- zip -r -q - .; else set -- cat \"$file\"; fi; else set -- cat; fi; url=$(\"$@\" | curl --silent --show-error --progress-bar --upload-file \"-\" \"https:\u002F\u002Ftransfer.sh\u002F$file_name\"); echo \"$url\"; )\n```\n\n\u003Cbr \u002F>\n\n#### Now you can use transfer function\n```\n$ transfer hello.txt\n```\n\n\u003Cbr \u002F>\n\n### Bash and zsh (with delete url, delete token output and prompt before uploading)\n##### Add this to .bashrc or .zshrc or its equivalent\n\n\u003Cdetails>\u003Csummary>Expand\u003C\u002Fsummary>\u003Cp>\n\n```bash\ntransfer()\n{\n    local file\n    declare -a file_array\n    file_array=(\"${@}\")\n\n    if [[ \"${file_array[@]}\" == \"\" || \"${1}\" == \"--help\" || \"${1}\" == \"-h\" ]]\n    then\n        echo \"${0} - Upload arbitrary files to \\\"transfer.sh\\\".\"\n        echo \"\"\n        echo \"Usage: ${0} [options] [\u003Cfile>]...\"\n        echo \"\"\n        echo \"OPTIONS:\"\n        echo \"  -h, --help\"\n        echo \"      show this message\"\n        echo \"\"\n        echo \"EXAMPLES:\"\n        echo \"  Upload a single file from the current working directory:\"\n        echo \"      ${0} \\\"image.img\\\"\"\n        echo \"\"\n        echo \"  Upload multiple files from the current working directory:\"\n        echo \"      ${0} \\\"image.img\\\" \\\"image2.img\\\"\"\n        echo \"\"\n        echo \"  Upload a file from a different directory:\"\n        echo \"      ${0} \\\"\u002Ftmp\u002Fsome_file\\\"\"\n        echo \"\"\n        echo \"  Upload all files from the current working directory. Be aware of the webserver's rate limiting!:\"\n        echo \"      ${0} *\"\n        echo \"\"\n        echo \"  Upload a single file from the current working directory and filter out the delete token and download link:\"\n        echo \"      ${0} \\\"image.img\\\" | awk --field-separator=\\\": \\\" '\u002FDelete token:\u002F { print \\$2 } \u002FDownload link:\u002F { print \\$2 }'\"\n        echo \"\"\n        echo \"  Show help text from \\\"transfer.sh\\\":\"\n        echo \"      curl --request GET \\\"https:\u002F\u002Ftransfer.sh\\\"\"\n        return 0\n    else\n        for file in \"${file_array[@]}\"\n        do\n            if [[ ! -f \"${file}\" ]]\n            then\n                echo -e \"\\e[01;31m'${file}' could not be found or is not a file.\\e[0m\" >&2\n                return 1\n            fi\n        done\n        unset file\n    fi\n\n    local upload_files\n    local curl_output\n    local awk_output\n\n    du -c -k -L \"${file_array[@]}\" >&2\n    # be compatible with \"bash\"\n    if [[ \"${ZSH_NAME}\" == \"zsh\" ]]\n    then\n        read $'upload_files?\\e[01;31mDo you really want to upload the above files ('\"${#file_array[@]}\"$') to \"transfer.sh\"? (Y\u002Fn): \\e[0m'\n    elif [[ \"${BASH}\" == *\"bash\"* ]]\n    then\n        read -p $'\\e[01;31mDo you really want to upload the above files ('\"${#file_array[@]}\"$') to \"transfer.sh\"? (Y\u002Fn): \\e[0m' upload_files\n    fi\n\n    case \"${upload_files:-y}\" in\n        \"y\"|\"Y\")\n            # for the sake of the progress bar, execute \"curl\" for each file.\n            # the parameters \"--include\" and \"--form\" will suppress the progress bar.\n            for file in \"${file_array[@]}\"\n            do\n                # show delete link and filter out the delete token from the response header after upload.\n                # it is important to save \"curl's\" \"stdout\" via a subshell to a variable or redirect it to another command,\n                # which just redirects to \"stdout\" in order to have a sane output afterwards.\n                # the progress bar is redirected to \"stderr\" and is only displayed,\n                # if \"stdout\" is redirected to something; e.g. \">\u002Fdev\u002Fnull\", \"tee \u002Fdev\u002Fnull\" or \"| \u003Csome_command>\".\n                # the response header is redirected to \"stdout\", so redirecting \"stdout\" to \"\u002Fdev\u002Fnull\" does not make any sense.\n                # redirecting \"curl's\" \"stderr\" to \"stdout\" (\"2>&1\") will suppress the progress bar.\n                curl_output=$(curl --request PUT --progress-bar --dump-header - --upload-file \"${file}\" \"https:\u002F\u002Ftransfer.sh\u002F\")\n                awk_output=$(awk \\\n                    'gsub(\"\\r\", \"\", $0) && tolower($1) ~ \u002Fx-url-delete\u002F \\\n                    {\n                        delete_link=$2;\n                        print \"Delete command: curl --request DELETE \" \"\\\"\"delete_link\"\\\"\";\n\n                        gsub(\".*\u002F\", \"\", delete_link);\n                        delete_token=delete_link;\n                        print \"Delete token: \" delete_token;\n                    }\n\n                    END{\n                        print \"Download link: \" $0;\n                    }' \u003C\u003C\u003C \"${curl_output}\")\n\n                # return the results via \"stdout\", \"awk\" does not do this for some reason.\n                echo -e \"${awk_output}\\n\"\n\n                # avoid rate limiting as much as possible; nginx: too many requests.\n                if (( ${#file_array[@]} > 4 ))\n                then\n                    sleep 5\n                fi\n            done\n            ;;\n\n        \"n\"|\"N\")\n            return 1\n            ;;\n\n        *)\n            echo -e \"\\e[01;31mWrong input: '${upload_files}'.\\e[0m\" >&2\n            return 1\n    esac\n}\n```\n\n\u003C\u002Fp>\u003C\u002Fdetails>\n\n#### Sample output\n```bash\n$ ls -lh\ntotal 20M\n-rw-r--r-- 1 \u003Csome_username> \u003Csome_username> 10M Apr  4 21:08 image.img\n-rw-r--r-- 1 \u003Csome_username> \u003Csome_username> 10M Apr  4 21:08 image2.img\n$ transfer image*\n10240K  image2.img\n10240K  image.img\n20480K  total\nDo you really want to upload the above files (2) to \"transfer.sh\"? (Y\u002Fn):\n######################################################################################################################################################################################################################################## 100.0%\nDelete command: curl --request DELETE \"https:\u002F\u002Ftransfer.sh\u002FwJw9pz\u002Fimage2.img\u002FmSctGx7pYCId\"\nDelete token: mSctGx7pYCId\nDownload link: https:\u002F\u002Ftransfer.sh\u002FwJw9pz\u002Fimage2.img\n\n######################################################################################################################################################################################################################################## 100.0%\nDelete command: curl --request DELETE \"https:\u002F\u002Ftransfer.sh\u002FljJc5I\u002Fimage.img\u002Fnw7qaoiKUwCU\"\nDelete token: nw7qaoiKUwCU\nDownload link: https:\u002F\u002Ftransfer.sh\u002FljJc5I\u002Fimage.img\n\n$ transfer \"image.img\" | awk --field-separator=\": \" '\u002FDelete token:\u002F { print $2 } \u002FDownload link:\u002F { print $2 }'\n10240K  image.img\n10240K  total\nDo you really want to upload the above files (1) to \"transfer.sh\"? (Y\u002Fn):\n######################################################################################################################################################################################################################################## 100.0%\ntauN5dE3fWJe\nhttps:\u002F\u002Ftransfer.sh\u002FMYkuqn\u002Fimage.img\n```\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Contributions\n\nContributions are welcome.\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Creators\n\n**Remco Verhoef**\n- \u003Chttps:\u002F\u002Ftwitter.com\u002Fremco_verhoef>\n- \u003Chttps:\u002F\u002Ftwitter.com\u002Fdutchcoders>\n\n**Uvis Grinfelds**\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Maintainers\n\n- **Andrea Spacca**\n- **Stefan Benten**\n\n\u003Cbr \u002F>\n\n---\n\n\u003Cbr \u002F>\n\n## Copyright and License\n\nCode and documentation copyright 2011-2018 Remco Verhoef.\nCode and documentation copyright 2018-2020 Andrea Spacca.\nCode and documentation copyright 2020- Andrea Spacca and Stefan Benten.\n\nCode released under [the MIT license](LICENSE).\n","transfer.sh 是一个基于命令行的快速文件分享工具。它支持通过简单的curl命令实现文件上传、下载及加密等功能，并且可以与Amazon S3, Google Drive, Storj等云存储服务集成，同时也支持本地文件系统。该项目采用Go语言编写，保证了高性能和跨平台性；同时提供Docker镜像，便于部署和扩展。非常适合需要从终端快速分享文件的技术人员使用，也适合企业内部搭建私有的文件传输服务。",2,"2026-06-11 03:01:14","top_language"]