Skip to content

Commit

Permalink
fix aws-sso version and homebrew
Browse files Browse the repository at this point in the history
  • Loading branch information
synfinatic committed Feb 25, 2023
1 parent 7ee77fe commit 9e6e9c2
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 3 deletions.
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# AWS SSO CLI Changelog

## [v1.9.8] - 2023-02-25

### Bugs

* `aws-sso version` no longer requires a valid config file

### Changes

* Update location for homebrew template file

## [v1.9.7] - 2023-02-25

### Bugs
Expand Down
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
PROJECT_VERSION := 1.9.7
PROJECT_VERSION := 1.9.8
DOCKER_REPO := synfinatic
PROJECT_NAME := aws-sso

Expand Down Expand Up @@ -77,15 +77,15 @@ shasum:
@echo "foo" | shasum -a 256 >/dev/null || (echo "'shasum' does not support: -a 256"; exit 1)

.PHONY: $(HOMEBREW)
$(HOMEBREW): homebrew/template.rb shasum ## no-help
$(HOMEBREW): homebrew/template.rb.m4 shasum ## no-help
TEMPFILE=$$(mktemp) && wget -q -O $${TEMPFILE} $(DOWNLOAD_URL) ; \
if test -s $${TEMPFILE}; then \
export SHA=$$(cat $${TEMPFILE} | shasum -a 256 | sed -e 's| -||') && rm $${TEMPFILE} && \
m4 -D __SHA256__=$${SHA} \
-D __VERSION__=$(PROJECT_VERSION) \
-D __COMMIT__=$(PROJECT_COMMIT) \
-D __URL__=$(DOWNLOAD_URL) \
homebrew/template.rb | tee $(HOMEBREW) && \
homebrew/template.rb.m4 | tee $(HOMEBREW) && \
echo "***** Please review above and test! ******" && \
echo "File written to: $(HOMEBREW) Please commit in git submodule!" ; \
else \
Expand Down
8 changes: 8 additions & 0 deletions cmd/aws-sso/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,14 @@ func main() {
Cli: &cli,
}

switch ctx.Command() {
case "Version":
if err = ctx.Run(&runCtx); err != nil {
log.Fatalf("Error running command: %s", err.Error())
}
return
}

// Load the config file
cli.ConfigFile = utils.GetHomePath(cli.ConfigFile)

Expand Down

0 comments on commit 9e6e9c2

Please sign in to comment.