Skip to content

Commit

Permalink
Replace $GOBIN with $GOPATH/bin
Browse files Browse the repository at this point in the history
  • Loading branch information
alessio committed May 3, 2019
1 parent 639a9c9 commit bd46ee5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 28 deletions.
23 changes: 1 addition & 22 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ defaults: &linux_defaults
working_directory: /go/src/github.com/cosmos/cosmos-sdk
docker:
- image: circleci/golang:1.12.4
environment:
GOBIN: /tmp/workspace/bin


############
Expand All @@ -25,8 +23,7 @@ set_macos_env: &macos_env
command: |
echo 'export PATH=$PATH:$HOME/go/bin' >> $BASH_ENV
echo 'export GOPATH=$HOME/project' >> $BASH_ENV
echo 'export GOBIN=$GOPATH/bin' >> $BASH_ENV
echo 'export PATH=$PATH:$HOME/go/bin:$GOBIN' >> $BASH_ENV
echo 'export PATH=$PATH:$HOME/go/bin:$GOPATH/bin' >> $BASH_ENV
echo 'export GO111MODULE=on'
############
Expand All @@ -40,12 +37,6 @@ docs_update: &docs_deploy
environment:
AWS_REGION: us-east-1

deps: &dependencies
run:
name: dependencies
command: |
export PATH="$GOBIN:$PATH"
jobs:
setup_dependencies:
<<: *linux_defaults
Expand All @@ -59,13 +50,11 @@ jobs:
- run:
name: tools
command: |
export PATH="$GOBIN:$PATH"
make tools
- *dependencies
- run:
name: binaries
command: |
export PATH="$GOBIN:$PATH"
make go-mod-cache
make install
- save_cache:
Expand All @@ -92,7 +81,6 @@ jobs:
- run:
name: Lint source
command: |
export PATH="$GOBIN:$PATH"
make ci-lint
integration_tests:
Expand All @@ -109,7 +97,6 @@ jobs:
- run:
name: Test cli
command: |
export PATH="$GOBIN:$PATH"
make test_cli
test_sim_gaia_nondeterminism:
Expand All @@ -126,7 +113,6 @@ jobs:
- run:
name: Test individual module simulations
command: |
export PATH="$GOBIN:$PATH"
make test_sim_gaia_nondeterminism
test_sim_gaia_fast:
Expand All @@ -143,7 +129,6 @@ jobs:
- run:
name: Test full Gaia simulation
command: |
export PATH="$GOBIN:$PATH"
make test_sim_gaia_fast
test_sim_gaia_import_export:
Expand All @@ -160,7 +145,6 @@ jobs:
- run:
name: Test Gaia import/export simulation
command: |
export PATH="$GOBIN:$PATH"
make test_sim_gaia_import_export
test_sim_gaia_simulation_after_import:
Expand All @@ -177,7 +161,6 @@ jobs:
- run:
name: Test Gaia import/export simulation
command: |
export PATH="$GOBIN:$PATH"
make test_sim_gaia_simulation_after_import
test_sim_gaia_multi_seed_long:
Expand All @@ -194,7 +177,6 @@ jobs:
- run:
name: Test multi-seed Gaia simulation long
command: |
export PATH="$GOBIN:$PATH"
export GO111MODULE=on
make runsim
runsim 500 50 TestFullGaiaSimulation
Expand All @@ -213,7 +195,6 @@ jobs:
- run:
name: Test multi-seed Gaia simulation short
command: |
export PATH="$GOBIN:$PATH"
export GO111MODULE=on
make runsim
runsim 50 10 TestFullGaiaSimulation
Expand All @@ -233,7 +214,6 @@ jobs:
- run:
name: Run tests
command: |
export PATH="$GOBIN:$PATH"
export VERSION="$(git describe --tags --long | sed 's/v\(.*\)/\1/')"
export GO111MODULE=on
for pkg in $(go list ./... | grep -v github.com/cosmos/cosmos-sdk/cmd/gaia/cli_test | grep -v '/simulation' | circleci tests split --split-by=timings); do
Expand Down Expand Up @@ -283,7 +263,6 @@ jobs:
machine:
image: circleci/classic:latest
environment:
GOBIN: /home/circleci/.go_workspace/bin
GOPATH: /home/circleci/.go_workspace/
GOOS: linux
GOARCH: amd64
Expand Down
12 changes: 6 additions & 6 deletions cmd/gaia/sims.mk
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
########################################
### Simulations

runsim: $(GOBIN)/runsim
$(GOBIN)/runsim: contrib/runsim/main.go
runsim: $(GOPATH)/bin/runsim
$(GOPATH)/bin/runsim: contrib/runsim/main.go
go install github.com/cosmos/cosmos-sdk/cmd/gaia/contrib/runsim

sim-gaia-nondeterminism:
Expand All @@ -23,20 +23,20 @@ sim-gaia-fast:

sim-gaia-import-export: runsim
@echo "Running Gaia import/export simulation. This may take several minutes..."
$(GOBIN)/runsim 50 5 TestGaiaImportExport
$(GOPATH)/bin/runsim 50 5 TestGaiaImportExport

sim-gaia-simulation-after-import: runsim
@echo "Running Gaia simulation-after-import. This may take several minutes..."
$(GOBIN)/runsim 50 5 TestGaiaSimulationAfterImport
$(GOPATH)/bin/runsim 50 5 TestGaiaSimulationAfterImport

sim-gaia-custom-genesis-multi-seed: runsim
@echo "Running multi-seed custom genesis simulation..."
@echo "By default, ${HOME}/.gaiad/config/genesis.json will be used."
$(GOBIN)/runsim -g ${HOME}/.gaiad/config/genesis.json 400 5 TestFullGaiaSimulation
$(GOPATH)/bin/runsim -g ${HOME}/.gaiad/config/genesis.json 400 5 TestFullGaiaSimulation

sim-gaia-multi-seed: runsim
@echo "Running multi-seed Gaia simulation. This may take awhile!"
$(GOBIN)/runsim 400 5 TestFullGaiaSimulation
$(GOPATH)/bin/runsim 400 5 TestFullGaiaSimulation

sim-benchmark-invariants:
@echo "Running simulation invariant benchmarks..."
Expand Down

0 comments on commit bd46ee5

Please sign in to comment.