Skip to content

Commit

Permalink
Add make command for listing the SDK's complete set of Go dependencies (
Browse files Browse the repository at this point in the history
#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.
  • Loading branch information
jasdel committed Apr 25, 2022
1 parent d27c530 commit 7065f83
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
15 changes: 15 additions & 0 deletions Makefile
Expand Up @@ -466,6 +466,21 @@ sdkv1check:
echo "$$sdkv1usage"; \
if [ "$$sdkv1usage" != "" ]; then exit 1; fi

list-deps: list-deps-.

list-deps-%:
@# command that uses the pattern to define the root path that the
@# module testing will start from. Strips off the "list-deps-" and
@# replaces all "_" with "/".
@#
@# Trim output to only include stdout for list of dependencies only.
@# make list-deps 2>&-
@#
@# e.g. list-deps-internal_protocoltest
@cd ./internal/repotools/cmd/eachmodule \
&& go run . -p $(subst _,/,$(subst list-deps-,,$@)) ${EACHMODULE_FLAGS} \
"go list -m all | grep -v 'github.com/aws/aws-sdk-go-v2'" | sort -u

###################
# Sandbox Testing #
###################
Expand Down
2 changes: 1 addition & 1 deletion example/service/dynamodb/createTable/go.mod
@@ -1,4 +1,4 @@
module aws-sdk-go-v2/example/service/dynamodb/createTable
module github.com/aws/aws-sdk-go-v2/example/service/dynamodb/createTable

go 1.15

Expand Down

0 comments on commit 7065f83

Please sign in to comment.