#!/bin/sh
set -e
# check to see if gnatsd folder is empty
if [ ! "$(ls -A $HOME/gnatsd)" ]; then
  mkdir -p $HOME/gnatsd
  cd $HOME/gnatsd
  wget https://github.com/nats-io/gnatsd/releases/download/v0.9.2/gnatsd-v0.9.2-linux-amd64.zip -O gnatsd.zip
  unzip gnatsd.zip
  mv gnatsd-v0.9.2-linux-amd64/gnatsd .
else
  echo 'Using cached directory.';
fi

#!/bin/sh
set -e
# check to see if gnatsd folder is empty
if [ ! "$(ls -A $HOME/gnatsd)" ]; then
  mkdir -p $HOME/gnatsd
  cd $HOME/gnatsd
  wget https://github.com/nats-io/gnatsd/releases/download/v0.9.4/gnatsd-v0.9.4-linux-amd64.zip -O gnatsd.zip
  unzip gnatsd.zip
  mv gnatsd-v0.9.4-linux-amd64/gnatsd .
else
  echo 'Using cached directory.';
fi

Update NATS Server to latest release v0.9.4 for tests
Update NATS Server to latest release v0.9.4 for tests

The install gnatsd script now downloads the v0.9.4 NATS Server.
