diff options
author | Jacob Vosmaer <jacob@gitlab.com> | 2017-04-12 12:09:38 +0200 |
---|---|---|
committer | Jacob Vosmaer <jacob@gitlab.com> | 2017-04-12 12:37:14 +0200 |
commit | 015bf11a7ff902b51ad8c2e003bc340f5d056fd6 (patch) | |
tree | 4533b18a79b2696f46a106f849638c0f9342ca85 /bin | |
parent | 0fba550db58ca508cd92c88e1751e9362b60f100 (diff) | |
download | gitlab-shell-015bf11a7ff902b51ad8c2e003bc340f5d056fd6.tar.gz |
Better variable name
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/compile | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/bin/compile b/bin/compile index e9936ee..faf3e4c 100755 --- a/bin/compile +++ b/bin/compile @@ -6,20 +6,20 @@ require 'fileutils' require_relative '../lib/gitlab_init' GO_DIR = 'go' -GOPATH = File.join(ROOT_PATH, 'go_build') +BUILD_DIR = File.join(ROOT_PATH, 'go_build') GO_PACKAGE = File.join('gitlab.com/gitlab-org/gitlab-shell', GO_DIR) def main - FileUtils.rm_rf(GOPATH) - build_source_dir = File.join(GOPATH, 'src', GO_PACKAGE) + FileUtils.rm_rf(BUILD_DIR) + build_source_dir = File.join(BUILD_DIR, 'src', GO_PACKAGE) FileUtils.mkdir_p(build_source_dir) FileUtils.cp_r(File.join(ROOT_PATH, GO_DIR, '.'), build_source_dir) env = { - 'GOPATH' => GOPATH, + 'GOPATH' => BUILD_DIR, 'GO15VENDOREXPERIMENT' => '1', } run!(env, %W[go install #{GO_PACKAGE}/cmd/...]) - executables = Dir[File.join(GOPATH, 'bin', '*')] + executables = Dir[File.join(BUILD_DIR, 'bin', '*')] FileUtils.chmod(0755, executables) FileUtils.cp(executables, File.join(ROOT_PATH, 'bin')) end |