move scripts into the scripts/ folder

This commit is contained in:
Mitchell Hashimoto 2013-06-19 22:44:02 -07:00
parent 641ece6376
commit 79f230b0b0
3 changed files with 13 additions and 5 deletions

View File

@ -8,7 +8,7 @@ all:
@echo "$(OK_COLOR)==> Installing dependencies$(NO_COLOR)"
@go get -d -v ./...
@echo "$(OK_COLOR)==> Building$(NO_COLOR)"
@./build.sh
@./scripts/build.sh
format:
go fmt ./...

View File

@ -6,6 +6,13 @@ OK_COLOR="\x1b[32;01m"
ERROR_COLOR="\x1b[31;01m"
WARN_COLOR="\x1b[33;01m"
# Get the parent directory of where this script is.
SOURCE="${BASH_SOURCE[0]}"
while [ -h "$SOURCE" ] ; do SOURCE="$(readlink "$SOURCE")"; done
DIR="$( cd -P "$( dirname "$SOURCE" )/.." && pwd )"
# Change into that directory
cd $DIR
# Compile the main Packer app
echo "${OK_COLOR}--> Compiling Packer${NO_COLOR}"

9
dist.sh → scripts/dist.sh Executable file → Normal file
View File

@ -1,12 +1,13 @@
#!/bin/bash
set -e
# Get the directory where this script is. This will also resolve
# any symlinks in the directory/script, so it will be the fully
# resolved path.
# Get the parent directory of where this script is.
SOURCE="${BASH_SOURCE[0]}"
while [ -h "$SOURCE" ] ; do SOURCE="$(readlink "$SOURCE")"; done
DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
DIR="$( cd -P "$( dirname "$SOURCE" )/.." && pwd )"
# Change into that dir because we expect that
cd $DIR
# Determine the version that we're building based on the contents
# of packer/version.go.