Advertisement
Twissel

BuildDocs script

Mar 29th, 2019
213
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.27 KB | None | 0 0
  1. #!/bin/sh
  2.  
  3. cd /var/www/html
  4. if git remote update >/dev/null 2>&1; then
  5.   if git status -uno | grep -q 'Your branch is behind'; then
  6.     make clean
  7.     git pull
  8.     make html
  9.     echo "Updated successfully"
  10.   else
  11.     echo "Up-to-date"
  12.   fi
  13. else
  14.   echo "Failed"
  15. fi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement