Prevent future msys2 updates from deleting the ProxSpace setup file

This commit is contained in:
gator96100 2020-01-26 00:37:14 +01:00
commit 478ea7e9f0
17 changed files with 11 additions and 406 deletions

View file

@ -0,0 +1,66 @@
PSVERSION="3.3"
export LANG=en_US.UTF-8
export PS1='\[\033]0;ProxSpace v$PSVERSION - $MSYSTEM:\w\007\033[32m\]pm3 \[\033[33m\]\w\[\033[0m\]$ '
export PATH=/gcc-arm-none-eabi/bin:$PATH
alias ls='ls -hF --color=auto'
check_install () {
pacman -Q $1 > /dev/null
if [ $? == 1 ]; then
pacman --noconfirm --overwrite='*' -S $1
fi
}
check_install_web () {
pacman -Q $1 | grep $2 > /dev/null
if [ $? == 1 ]; then
pacman --noconfirm --overwrite='*' -U $3
fi
}
clean_86 () {
rm -rf /mingw32/share/qt5/examples
pacman --noconfirm --overwrite='*' -Scc
}
clean_64 () {
rm -rf /mingw64/share/qt5/examples
pacman --noconfirm --overwrite='*' -Scc
}
setup_proxspace ()
{
if [ "$MSYSTEM" == "MINGW64" ]; then
check_install mingw-w64-x86_64-gcc
check_install mingw-w64-x86_64-readline
check_install mingw-w64-x86_64-libsndfile
check_install git
check_install make
check_install pkg-config
check_install mingw-w64-x86_64-qt5
clean_64
fi
if [ "$MSYSTEM" == "MINGW32" ]; then
check_install mingw-w64-i686-readline
check_install mingw-w64-i686-gcc
check_install mingw-w64-i686-libsndfile
check_install git
check_install make
check_install pkg-config
check_install mingw-w64-i686-qt5
clean_86
fi
}
if [ "$MAYBE_FIRST_START" = "false" ]; then
yes | pacman -Su
setup_proxspace
clear
else
yes | pacman -Syuu
fi