Skip to content

Instantly share code, notes, and snippets.

@MarkZhangTW
Last active July 26, 2021 03:12
Show Gist options
  • Save MarkZhangTW/36a4ffc2d47826759ccbf2def00efd06 to your computer and use it in GitHub Desktop.
Save MarkZhangTW/36a4ffc2d47826759ccbf2def00efd06 to your computer and use it in GitHub Desktop.
Download RPM files from yum/dnf
#!/usr/bin/env bash
for rpm in "$@"; do
mkdir -p $rpm
sudo yum install --downloadonly --downloaddir=$rpm -y $rpm
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment