Skip to content

Instantly share code, notes, and snippets.

@Zorg64
Zorg64 / download_gofile.sh
Last active June 30, 2024 08:54 — forked from shawnli87/download_gofile.sh
Bash script to download files from gofile.io
#!/bin/bash
# Prompts the user for a URL if not provided as a command-line argument.
# Extracts the ID from the given URL to use in API requests.
function promptForURL() {
local url="$1"
until [ -n "$url" ]; do
read -p "URL: " url
done
id=$(sed 's|.*gofile.io/d/||g' <<< "$url")