taler-deployment

Deployment scripts and configuration files
Log | Files | Refs | README

update_taler-systems.sh (926B)


      1 #!/bin/sh
      2 
      3 set -eu
      4 
      5 fetch () {
      6   git clean -fdx
      7   git fetch
      8   # reset to updated upstream branch, but only if we're tracking a branch
      9   branch=$(git rev-parse --abbrev-ref --symbolic-full-name @{u} 2>/dev/null || echo HEAD)
     10   git reset --hard "$branch"
     11 }
     12 
     13 # Assumes the repo was already checked out once.
     14 cd $HOME/taler-systems-www
     15 
     16 git checkout master -f
     17 fetch
     18 git submodule update --init --force
     19 ./bootstrap
     20 ./configure --baseurl="https://taler-systems.com/" --prefix=$HOME/www.taler-systems.com.wip
     21 make install
     22 
     23 chmod -R g+rx $HOME/www.taler-systems.com.wip/
     24 
     25 # Clean up 'ancient' version (before previous)
     26 rm -rf $HOME/www.taler-systems.com.old/
     27 # Finally, do two fast renames to make the current version active
     28 mv $HOME/www.taler-systems.com/ $HOME/www.taler-systems.com.old/ || true
     29 mv $HOME/www.taler-systems.com.wip/ $HOME/www.taler-systems.com/
     30 
     31 cd
     32 
     33 rsync -av --rsh=ssh www.taler-systems.com www@taler-systems.com:.