Merge pull request #1331 from gaul/travis/simplify

Simplify conditional statements
This commit is contained in:
Takeshi Nakatani 2020-07-12 12:52:21 +09:00 committed by GitHub
commit e72a64785b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -72,10 +72,8 @@ jobs:
- HOMEBREW_NO_AUTO_UPDATE=1 brew cask install osxfuse - HOMEBREW_NO_AUTO_UPDATE=1 brew cask install osxfuse
- S3FS_BREW_PACKAGES='cppcheck python3'; - S3FS_BREW_PACKAGES='cppcheck python3';
for s3fs_brew_pkg in ${S3FS_BREW_PACKAGES}; do for s3fs_brew_pkg in ${S3FS_BREW_PACKAGES}; do
brew list | grep -q ${s3fs_brew_pkg}; if brew list | grep -q ${s3fs_brew_pkg}; then
if [ $? -eq 0 ]; then if brew outdated | grep -q ${s3fs_brew_pkg}; then
brew outdated | grep -q ${s3fs_brew_pkg};
if [ $? -eq 0 ]; then
echo "==> Try to upgrade ${s3fs_brew_pkg}"; echo "==> Try to upgrade ${s3fs_brew_pkg}";
HOMEBREW_NO_AUTO_UPDATE=1 brew upgrade ${s3fs_brew_pkg}; HOMEBREW_NO_AUTO_UPDATE=1 brew upgrade ${s3fs_brew_pkg};
fi fi
@ -84,8 +82,7 @@ jobs:
HOMEBREW_NO_AUTO_UPDATE=1 brew install ${s3fs_brew_pkg}; HOMEBREW_NO_AUTO_UPDATE=1 brew install ${s3fs_brew_pkg};
fi; fi;
done done
- pip3 --version; - if pip3 --version; then
if [ $? -eq 0 ]; then
echo "==> Try to install awscli by pip3"; echo "==> Try to install awscli by pip3";
sudo -H pip3 install awscli; sudo -H pip3 install awscli;
else else