Skip to content

Commit

Permalink
Use go run instead of prebuilt binaries
Browse files Browse the repository at this point in the history
  • Loading branch information
mono0x committed Aug 13, 2024
1 parent 03621d2 commit 74a8465
Show file tree
Hide file tree
Showing 4 changed files with 77 additions and 79 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/.env
/bin/
/my-scraper
/my-scraper.linux
/tmp/
8 changes: 2 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@ BINARY=my-scraper

all: deps test build

setup:
GOBIN=$(GOBIN) $(GO) install github.com/cosmtrek/air
GOBIN=$(GOBIN) $(GO) install honnef.co/go/tools/cmd/staticcheck

download:
$(GO) mod download

Expand All @@ -24,7 +20,7 @@ test:
$(GO) mod verify
$(GO) vet ./...
$(GO) test $(TESTOPTS)
$(GOBIN)/staticcheck ./...
go run honnef.co/go/tools/cmd/staticcheck ./...

build:
$(GO) build -o $(BINARY) $(BUILDOPTS)
Expand All @@ -33,4 +29,4 @@ build-docker:
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 $(GO) build -o /bin/$(BINARY) $(BUILDOPTS)

watch:
$(GOBIN)/air
go run github.com/cosmtrek/air
39 changes: 20 additions & 19 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
module github.com/mono0x/my-scraper

go 1.22
go 1.22.1

toolchain go1.23.0

require (
github.com/PuerkitoBio/goquery v1.9.2
Expand All @@ -10,19 +12,19 @@ require (
github.com/joho/godotenv v1.5.1
github.com/stretchr/testify v1.9.0
github.com/victorspringer/http-cache v0.0.0-20240523143319-7d9f48f8ab91
golang.org/x/oauth2 v0.21.0
golang.org/x/sync v0.7.0
golang.org/x/text v0.16.0
google.golang.org/api v0.189.0
honnef.co/go/tools v0.4.7
golang.org/x/oauth2 v0.22.0
golang.org/x/sync v0.8.0
golang.org/x/text v0.17.0
google.golang.org/api v0.191.0
honnef.co/go/tools v0.5.0
)

require (
cloud.google.com/go/auth v0.7.2 // indirect
cloud.google.com/go/auth/oauth2adapt v0.2.3 // indirect
cloud.google.com/go/auth v0.8.0 // indirect
cloud.google.com/go/auth/oauth2adapt v0.2.4 // indirect
cloud.google.com/go/compute/metadata v0.5.0 // indirect
dario.cat/mergo v1.0.0 // indirect
github.com/BurntSushi/toml v1.4.0 // indirect
github.com/BurntSushi/toml v1.4.1-0.20240526193622-a339e1f7089c // indirect
github.com/andybalholm/cascadia v1.3.2 // indirect
github.com/bep/godartsass v1.2.0 // indirect
github.com/bep/godartsass/v2 v2.1.0 // indirect
Expand All @@ -36,33 +38,32 @@ require (
github.com/go-logr/logr v1.4.2 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/gobwas/glob v0.2.3 // indirect
github.com/gohugoio/hugo v0.129.0 // indirect
github.com/gohugoio/hugo v0.132.1 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/google/s2a-go v0.1.8 // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect
github.com/googleapis/gax-go/v2 v2.13.0 // indirect
github.com/mattn/go-colorable v0.1.13 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
github.com/mitchellh/hashstructure v1.1.0 // indirect
github.com/pelletier/go-toml v1.9.5 // indirect
github.com/pelletier/go-toml/v2 v2.2.2 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/spf13/afero v1.11.0 // indirect
github.com/spf13/cast v1.6.0 // indirect
github.com/spf13/cast v1.7.0 // indirect
github.com/tdewolff/parse/v2 v2.7.15 // indirect
go.opencensus.io v0.24.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.53.0 // indirect
go.opentelemetry.io/otel v1.28.0 // indirect
go.opentelemetry.io/otel/metric v1.28.0 // indirect
go.opentelemetry.io/otel/trace v1.28.0 // indirect
golang.org/x/crypto v0.25.0 // indirect
golang.org/x/exp/typeparams v0.0.0-20240719175910-8a7402abbf56 // indirect
golang.org/x/mod v0.19.0 // indirect
golang.org/x/net v0.27.0 // indirect
golang.org/x/sys v0.22.0 // indirect
golang.org/x/tools v0.23.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240723171418-e6d459c13d2a // indirect
golang.org/x/crypto v0.26.0 // indirect
golang.org/x/exp/typeparams v0.0.0-20240808152545-0cdaa3abc0fa // indirect
golang.org/x/mod v0.20.0 // indirect
golang.org/x/net v0.28.0 // indirect
golang.org/x/sys v0.24.0 // indirect
golang.org/x/tools v0.24.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240812133136-8ffd90a71988 // indirect
google.golang.org/grpc v1.65.0 // indirect
google.golang.org/protobuf v1.34.2 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
Expand Down
Loading

0 comments on commit 74a8465

Please sign in to comment.