Skip to content

Commit

Permalink
[chore] Remove GO111MODULE references (#10039)
Browse files Browse the repository at this point in the history
This has been set to `on` by default since Go 1.16:
https://go.dev/doc/go1.16#go-command.

Co-authored-by: Evan Bradley <evan-bradley@users.noreply.github.com>
  • Loading branch information
evan-bradley and evan-bradley authored Apr 29, 2024
1 parent ce09d97 commit c9ecdfb
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 7 deletions.
5 changes: 1 addition & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -206,10 +206,7 @@ before merging (but see above paragraph about writing good commit messages in th

This project uses Go 1.21.* and [Github Actions.](https://github.com/features/actions)

It is recommended to run `make gofmt all` before submitting your PR

The dependencies are managed with `go mod` if you work with the sources under your
`$GOPATH` you need to set the environment variable `GO111MODULE=on`.
It is recommended to run `make gofmt all` before submitting your PR.

## Coding Guidelines

Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ endif
# Build the Collector executable.
.PHONY: otelcorecol
otelcorecol:
pushd cmd/otelcorecol && GO111MODULE=on CGO_ENABLED=0 $(GOCMD) build -trimpath -o ../../bin/otelcorecol_$(GOOS)_$(GOARCH) \
pushd cmd/otelcorecol && CGO_ENABLED=0 $(GOCMD) build -trimpath -o ../../bin/otelcorecol_$(GOOS)_$(GOARCH) \
-tags $(GO_BUILD_TAGS) ./cmd/otelcorecol && popd

.PHONY: genotelcorecol
Expand Down
2 changes: 1 addition & 1 deletion cmd/builder/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ include ../../Makefile.Common

.PHONY: ocb
ocb:
GO111MODULE=on CGO_ENABLED=0 $(GOCMD) build -trimpath -o ../../bin/ocb_$(GOOS)_$(GOARCH) .
CGO_ENABLED=0 $(GOCMD) build -trimpath -o ../../bin/ocb_$(GOOS)_$(GOARCH) .

# Generate the default build config from otelcorecol, by removing the
# "replaces" stanza, which is assumed to be at the end of the file.
Expand Down
2 changes: 1 addition & 1 deletion cmd/builder/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ This program generates a custom OpenTelemetry Collector binary based on a given
## TL;DR

```console
$ GO111MODULE=on go install go.opentelemetry.io/collector/cmd/builder@latest
$ go install go.opentelemetry.io/collector/cmd/builder@latest
$ cat > otelcol-builder.yaml <<EOF
dist:
name: otelcol-custom
Expand Down

0 comments on commit c9ecdfb

Please sign in to comment.