github.com/trevoraustin/hub@v2.2.0-preview1.0.20141105230840-96d8bfc654cc+incompatible/script/godep (about)

     1  #!/usr/bin/env bash
     2  # Usage: script/build [test]
     3  #
     4  # Sets up GOPATH and run command
     5  
     6  set -e
     7  
     8  TMP_GOPATH="${TMPDIR:-/tmp}/go"
     9  TMP_SELF="${TMP_GOPATH}/src/github.com/github/hub"
    10  
    11  export GOPATH="${TMP_GOPATH}:${PWD}/Godeps/_workspace:$GOPATH"
    12  
    13  if [ ! -e "$TMP_SELF" ]; then
    14    mkdir -p "${TMP_SELF%/*}"
    15    ln -snf "$PWD" "$TMP_SELF"
    16  fi
    17  
    18  $@