papirus-icon-theme/install-papirus-home-gtk.sh

61 lines
1.6 KiB
Bash
Raw Normal View History

2016-11-25 18:38:40 -05:00
#!/bin/sh
set -e
2016-11-27 07:32:03 -05:00
gh_repo="papirus-icon-theme"
2016-11-28 05:54:17 -05:00
gh_desc="Papirus icon theme GTK"
2016-11-26 10:10:12 -05:00
cat <<- EOF
2016-11-25 18:38:40 -05:00
ppppp ii
pp pp aaaaa ppppp rr rrr uu uu sssss
ppppp aa aa pp pp ii rrrr uu uu ssss
pp aa aa pp pp ii rr uu uu ssss
pp aaaaa ppppp ii rr uuuuu sssss
pp
pp
2016-11-26 10:10:12 -05:00
$gh_desc
https://github.com/PapirusDevelopmentTeam/$gh_repo
2016-11-25 18:38:40 -05:00
EOF
temp_dir=$(mktemp -d)
echo "=> Getting the latest version from GitHub ..."
2016-11-26 10:14:44 -05:00
wget -O "/tmp/$gh_repo.tar.gz" \
2016-11-26 10:10:12 -05:00
https://github.com/PapirusDevelopmentTeam/$gh_repo/archive/master.tar.gz
2016-11-25 18:38:40 -05:00
echo "=> Unpacking archive ..."
2016-11-26 10:10:12 -05:00
tar -xzf "/tmp/$gh_repo.tar.gz" -C "$temp_dir"
2016-11-26 10:10:12 -05:00
echo "=> Deleting old $gh_desc ..."
2016-12-21 23:44:04 -05:00
rm -rf ~/.icons/ePapirus
2016-11-28 05:54:17 -05:00
rm -rf ~/.icons/Papirus
rm -rf ~/.icons/Papirus-Adapta
2016-11-28 05:54:17 -05:00
rm -rf ~/.icons/Papirus-Dark
2017-03-05 17:44:44 -05:00
rm -rf ~/.icons/Papirus-Light
2016-11-25 18:38:40 -05:00
echo "=> Installing ..."
mkdir -p ~/.icons
cp -R \
2016-12-21 23:44:04 -05:00
"$temp_dir/$gh_repo-master/ePapirus" \
2016-11-27 07:32:03 -05:00
"$temp_dir/$gh_repo-master/Papirus" \
"$temp_dir/$gh_repo-master/Papirus-Adapta" \
2017-03-05 17:44:44 -05:00
"$temp_dir/$gh_repo-master/Papirus-Dark" \
"$temp_dir/$gh_repo-master/Papirus-Light" ~/.icons/
2016-12-21 23:44:04 -05:00
gtk-update-icon-cache -q ~/.icons/ePapirus || true
2016-11-27 07:32:03 -05:00
gtk-update-icon-cache -q ~/.icons/Papirus || true
gtk-update-icon-cache -q ~/.icons/Papirus-Adapta || true
2016-11-27 07:32:03 -05:00
gtk-update-icon-cache -q ~/.icons/Papirus-Dark || true
2017-03-05 17:44:44 -05:00
gtk-update-icon-cache -q ~/.icons/Papirus-Light || true
2016-11-25 18:38:40 -05:00
echo "=> Clearing cache ..."
2016-11-26 10:10:12 -05:00
rm -rf "/tmp/$gh_repo.tar.gz" "$temp_dir"
2016-11-25 18:38:40 -05:00
echo "=> Done!"