Skip to content
This repository has been archived by the owner on Nov 19, 2020. It is now read-only.

Commit

Permalink
Travis-CI integration static analysis shellcheck (#1)
Browse files Browse the repository at this point in the history
  • Loading branch information
denji committed Mar 18, 2017
1 parent b4b4e0e commit e7291c2
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
7 changes: 7 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
language: bash
install: |
wget 'http://ftp.debian.org/debian/pool/main/s/shellcheck/shellcheck_0.4.4-4_amd64.deb' && \
sudo dpkg -i shellcheck_*.deb
script:
- shellcheck -s bash -e SC1083 jetbrains-backup.sh || exit 1;
- shellcheck -s bash -e SC1083 jetbrains-uninstall.sh || exit 1;
4 changes: 2 additions & 2 deletions jetbrains-backup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
set -u
FILE=~/Desktop/JetBrains-$(date "+%Y%m%d-%H%M%S").tar.xz

if [ "`uname -s`" != "Darwin" ] ; then
if [ "$(uname -s)" != "Darwin" ] ; then
echo "Sorry, $(uname -s) is not supported yet."
exit 1
fi
Expand Down Expand Up @@ -50,5 +50,5 @@ tar pf "$FILE" --append ~/Library/{Preferences,Caches,Application\ Support,Logs}
tar pf "$FILE" --append ~/Library/{Preferences,Caches,Application\ Support,Logs}/WebStorm{?,??,20??.*,-EAP} &>/dev/null

echo 'Check backup all data before deleting the product'
echo "The configuration backup is successfully created: $FILE (size: $(du -sh $FILE|cut -f1))"
echo "The configuration backup is successfully created: $FILE (size: $(du -sh "$FILE" | cut -f1))"
# open -R $FILE
2 changes: 1 addition & 1 deletion jetbrains-uninstall.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env bash
set -x

if [ "`uname -s`" != "Darwin" ] ; then
if [ "$(uname -s)" != "Darwin" ] ; then
echo "Sorry, $(uname -s) is not supported yet."
exit 1
fi
Expand Down

0 comments on commit e7291c2

Please sign in to comment.