Skip to content

Instantly share code, notes, and snippets.

@byStrange
Last active February 3, 2026 04:59
Show Gist options
  • Select an option

  • Save byStrange/63f4429447bf9f591221166aa7c090e8 to your computer and use it in GitHub Desktop.

Select an option

Save byStrange/63f4429447bf9f591221166aa7c090e8 to your computer and use it in GitHub Desktop.
#!/bin/bash
INSTALL_DIR="$HOME/.local/bin"
mkdir -p "$INSTALL_DIR"
curl -sL "https://gist.githubusercontent.com/byStrange/63f4429447bf9f591221166aa7c090e8/raw/6883d961b60b1d53d51dcdb5bab9b64750aaed2e/unmusic.sh" -o "$INSTALL_DIR/unmusic"
chmod +x "$INSTALL_DIR/unmusic"
# Add to PATH based on shell
SHELL_TYPE=$(basename "$SHELL")
if [ "$SHELL_TYPE" = "zsh" ]; then
PROFILE="$HOME/.zshrc"
elif [ "$SHELL_TYPE" = "bash" ]; then
PROFILE="$HOME/.bashrc"
else
PROFILE="$HOME/.profile"
fi
if ! grep -q "$INSTALL_DIR" "$PROFILE"; then
echo "export PATH=\"\$PATH:$INSTALL_DIR\"" >> "$PROFILE"
echo "βœ… Added to $PROFILE. Restart your terminal or run 'source $PROFILE'"
else
echo "βœ… Already in PATH."
fi
echo "πŸš€ Done! You can now run 'unmusic <URL>'"
#!/bin/bash
# Usage: ./remove_music.sh "YOUTUBE_URL"
USER="ron"
HOST="0.tcp.in.ngrok.io"
PORT=12528
REMOTE_SCRIPT="~/bin/gpu_worker.sh"
URL=$1
if [ -z "$URL" ]; then
echo "Usage: ./remove_music.sh <YOUTUBE_URL>"
exit 1
fi
echo "πŸš€ Connecting to GPU Server..."
echo "--> Sending Job for: $URL"
REMOTE_FILE=$(ssh -p $PORT "$USER@$HOST" "bash $REMOTE_SCRIPT \"$URL\"")
if [[ "$REMOTE_FILE" == *"ERROR"* ]] || [[ -z "$REMOTE_FILE" ]]; then
echo "Something went wrong on the server."
exit 1
fi
echo "--> Processing complete. Downloading file..."
scp -P $PORT "$USER@$HOST:$REMOTE_FILE" ./cleaned_vocals.mp3
echo "βœ… Done! Saved as 'cleaned_vocals.mp3'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment