Skip to content

Commit 7065f83

Browse files
authored
Add make command for listing the SDK's complete set of Go dependencies (#1677)
Updates the SDK's Makefile to include a command to list all dependencies across the SDK's modules. Also includes minor fix for the `example/service/dynamodb/createTable` example module to use the SDK's root module path.
1 parent d27c530 commit 7065f83

File tree

2 files changed

+16
-1
lines changed

2 files changed

+16
-1
lines changed

Makefile

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -466,6 +466,21 @@ sdkv1check:
466466
echo "$$sdkv1usage"; \
467467
if [ "$$sdkv1usage" != "" ]; then exit 1; fi
468468

469+
list-deps: list-deps-.
470+
471+
list-deps-%:
472+
@# command that uses the pattern to define the root path that the
473+
@# module testing will start from. Strips off the "list-deps-" and
474+
@# replaces all "_" with "/".
475+
@#
476+
@# Trim output to only include stdout for list of dependencies only.
477+
@# make list-deps 2>&-
478+
@#
479+
@# e.g. list-deps-internal_protocoltest
480+
@cd ./internal/repotools/cmd/eachmodule \
481+
&& go run . -p $(subst _,/,$(subst list-deps-,,$@)) ${EACHMODULE_FLAGS} \
482+
"go list -m all | grep -v 'github.com/aws/aws-sdk-go-v2'" | sort -u
483+
469484
###################
470485
# Sandbox Testing #
471486
###################

example/service/dynamodb/createTable/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
module aws-sdk-go-v2/example/service/dynamodb/createTable
1+
module github.com/aws/aws-sdk-go-v2/example/service/dynamodb/createTable
22

33
go 1.15
44

0 commit comments

Comments
 (0)