#!/bin/sh # Copying dangerous commands from the internet and forgetting to trim the `$` off the start? # Getting all sorts of `# -bash: $: command not found` errors? # This script is for you! # `$ command` will now ask for confirmation before executing the gum you scraped off of stackoverflow! echo "You are about to run the command:" echo "$@" read -n 1 -p "Do you want to continue? [yN]: " answer echo "" if [ "$answer" == "y" ]; then echo "--- executing ---" "$@" fi