Ever wanted to install an AUR package but don't want to install all those base-devel dependencies or just want to build an AUR package to install on other Arch environments without build dependencies?
Here's a Docker tool can do it for you.
docker pull 36web/aurpkg
docker run --rm --init -v $PWD:/pkg -e USER_ID=`id -u` -e GROUP_ID=`id -g` 36web/aurpkg PACKAGE_NAME
replace PACKAGE_NAME with the name of your desired package on AUR.
example:
docker run --rm --init -v $PWD:/pkg -e USER_ID=`id -u` -e GROUP_ID=`id -g` 36web/aurpkg telegram-desktop-bin
Docker will build the package and put it in the directory named as PACKAGE_NAME with PKGBUILD for package details. You may later install the package with
sudo pacman -U package.pkg.tar.xz
You may also make it an alias for further usage.
alias aurpkg='docker run --rm --init -v $PWD:/pkg -e USER_ID=`id -u` -e GROUP_ID=`id -g` 36web/aurpkg '
and just run
aurpkg PACKAGE_NAME
at anytime.