Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: elasticpath/epcc-cli
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v0.9.7
Choose a base ref
...
head repository: elasticpath/epcc-cli
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
Loading
Showing with 9,432 additions and 1,970 deletions.
  1. +4 −4 .github/workflows/release.yml
  2. +20 −5 .github/workflows/test.yml
  3. +2 −1 .gitignore
  4. +3 −5 .goreleaser.yaml
  5. +68 −37 README.md
  6. +3 −1 cmd/commercemanager.go
  7. +1 −1 cmd/configure.go
  8. +189 −185 cmd/create.go
  9. +0 −43 cmd/create_completion_test.go
  10. +153 −0 cmd/create_test.go
  11. +103 −0 cmd/crud_smoke_test.go
  12. +135 −19 cmd/delete-all.go
  13. +1 −0 cmd/delete-all_test.go
  14. +145 −152 cmd/delete.go
  15. +196 −0 cmd/delete_test.go
  16. +7 −3 cmd/docs.go
  17. +263 −200 cmd/get.go
  18. +193 −0 cmd/get_test.go
  19. +130 −0 cmd/headers.go
  20. +866 −0 cmd/helper.go
  21. +58 −49 cmd/login.go
  22. +14 −0 cmd/logout.go
  23. +33 −0 cmd/repeater.go
  24. +42 −9 cmd/reset-store.go
  25. +177 −99 cmd/root.go
  26. +16 −0 cmd/root_test.go
  27. +260 −85 cmd/runbooks.go
  28. +1 −1 cmd/test-json.go
  29. +146 −125 cmd/update.go
  30. +199 −0 cmd/update_test.go
  31. +18 −1 config/config.go
  32. +83 −10 docs/runbook-development.md
  33. +207 −94 docs/tutorial.md
  34. +146 −36 external/aliases/aliases.go
  35. +50 −21 external/authentication/auth.go
  36. +43 −0 external/authentication/internal_login.go
  37. +7 −3 external/autofill/autofill.go
  38. +6 −0 external/browser/browser.go
  39. +11 −0 external/clictx/ctx.go
  40. +204 −34 external/completion/completion.go
  41. +145 −0 external/completion/completion_test.go
  42. +266 −0 external/completion/filter_completion.go
  43. +70 −0 external/completion/filter_completion_test.go
  44. +55 −0 external/completion/headers.go
  45. +0 −5 external/crud/outstanding_request_counter.go
  46. +0 −6 external/crud/url_override.go
  47. +1 −1 external/encoding/multipart.go
  48. +234 −0 external/headergroups/headergroup.go
  49. +199 −0 external/headergroups/headergroup_test.go
  50. +6 −0 external/httpclient/http_overrides.go
  51. +147 −37 external/httpclient/httpclient.go
  52. +52 −0 external/json/compact.go
  53. +7 −0 external/json/encoder.go
  54. +12 −0 external/json/print_json.go
  55. +60 −11 external/json/to_json.go
  56. +159 −36 external/json/to_json_test.go
  57. +34 −0 external/misc/arg_tweaker.go
  58. +138 −0 external/oidc/callback.go
  59. +155 −0 external/oidc/get_token.go
  60. +160 −0 external/oidc/index.go
  61. +114 −0 external/oidc/server.go
  62. +52 −0 external/oidc/site/callback.gohtml
  63. BIN external/oidc/site/favicon.ico
  64. +5 −0 external/oidc/site/footer.gohtml
  65. +37 −0 external/oidc/site/get_token.gohtml
  66. +18 −0 external/oidc/site/header.gohtml
  67. +123 −0 external/oidc/site/index.gohtml
  68. +71 −0 external/oidc/site/static/light.svg
  69. +76 −0 external/oidc/site/static/style.css
  70. +16 −2 external/profiles/profiles.go
  71. +6 −1 external/profiles/requestlogs.go
  72. +38 −24 external/resources/resources.go
  73. +9 −8 external/resources/resources_schema.json
  74. +41 −7 external/resources/uritemplates.go
  75. +41 −2 external/resources/uritemplates_test.go
  76. +981 −392 external/resources/yaml/resources.yaml
  77. +143 −7 external/resources/yaml/resources_yaml_test.go
  78. +141 −0 external/rest/create.go
  79. +125 −0 external/rest/delete.go
  80. +130 −0 external/rest/get.go
  81. +100 −0 external/rest/update.go
  82. +132 −0 external/runbooks/account-cart-associations.epcc.yml
  83. +59 −21 external/runbooks/account-management.epcc.yml
  84. +55 −0 external/runbooks/commerce-extensions.epcc.yml
  85. +174 −0 external/runbooks/customer-cart-associations.epcc.yml
  86. +27 −4 external/runbooks/hello-world.epcc.yml
  87. +5 −4 external/runbooks/manual-gateway-how-to.epcc.yml
  88. +120 −0 external/runbooks/multi-location-inventory.epcc.yml
  89. +25 −17 external/runbooks/pxm-how-to.epcc.yml
  90. +128 −0 external/runbooks/run-all-runbooks.sh
  91. +11 −1 external/runbooks/runbook_rendering.go
  92. +5 −1 external/runbooks/runbook_schema.json
  93. +22 −3 external/runbooks/runbook_validation.go
  94. +45 −22 external/runbooks/runbook_validation_test.go
  95. +26 −14 external/runbooks/runbooks.go
  96. +1 −22 external/runbooks/runbooks_test.go
  97. +45 −0 external/runbooks/subscriptions.epcc.yml
  98. +5 −0 external/shutdown/op_counter.go
  99. +35 −0 external/templates/funcs.go
  100. +44 −0 external/templates/template.go
  101. +30 −23 go.mod
  102. +67 −76 go.sum
  103. +1 −0 main.go
8 changes: 4 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -26,13 +26,13 @@ jobs:
run: git fetch --prune --unshallow
-
name: Set up Go
uses: actions/setup-go@v3
uses: actions/setup-go@v5
with:
go-version: 1.19
go-version: '1.21'
-
name: Import GPG key
id: import_gpg
uses: crazy-max/ghaction-import-gpg@v5.2.0
uses: crazy-max/ghaction-import-gpg@v6.2.0
with:
# These secrets will need to be configured for the repository:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
@@ -43,7 +43,7 @@ jobs:
uses: goreleaser/goreleaser-action@v3
with:
version: latest
args: release --rm-dist
args: release --clean
env:
GPG_FINGERPRINT: ${{ steps.import_gpg.outputs.fingerprint }}
# GitHub sets this automatically
25 changes: 20 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -18,11 +18,12 @@ jobs:
name: Build
runs-on: ubuntu-latest
timeout-minutes: 15
concurrency: github
steps:
- name: Set up Go
uses: actions/setup-go@v3
uses: actions/setup-go@v5
with:
go-version: '1.19'
go-version: '1.21'
id: go

- name: Check out code into the Go module directory
@@ -43,13 +44,27 @@ jobs:
- name: Build
run: |
go build -o ./bin/epcc -v ./cmd/
go build -o ./bin/epcc -v ./
- name: Unit Tests
timeout-minutes: 15
env:
EPCC_CLIENT_ID: ${{ secrets.EPCC_CLIENT_ID }}
EPCC_CLIENT_SECRET: ${{ secrets.EPCC_CLIENT_SECRET }}
EPCC_API_BASE_URL: ${{ vars.EPCC_API_BASE_URL }}
run: |
go test -v -cover ./cmd/ ./external/...
- name: Runbook Smoke Test
timeout-minutes: 15
env:
EPCC_CLIENT_ID: ${{ secrets.EPCC_CLIENT_ID }}
EPCC_CLIENT_SECRET: ${{ secrets.EPCC_CLIENT_SECRET }}
EPCC_API_BASE_URL: ${{ vars.EPCC_API_BASE_URL }}
run: |
export PATH=./bin/:$PATH
./external/runbooks/run-all-runbooks.sh
- name: Run GoReleaser (for Linux build and Syntax check)
uses: goreleaser/goreleaser-action@v3
env:
@@ -60,8 +75,8 @@ jobs:
args: build --single-target --snapshot

- name: 'Upload Artifact'
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: distribution
path: dist/epcc-cli_linux_amd64
path: dist/epcc-cli_linux_amd64_v1/epcc
retention-days: 5
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -3,4 +3,5 @@ bin
dist/
epcc-cli
epcc
.envrc
.envrc
build/
8 changes: 3 additions & 5 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Visit https://goreleaser.com for documentation on how to customize this
# behavior.
version: 2
before:
hooks:
# this is just an example and not a requirement for provider building/publishing
@@ -38,9 +39,6 @@ nfpms:
# ID of the nfpm config, must be unique.
# Defaults to "default".
package_name: "epcc-cli"
replacements:
386: i386
darwin: macOS
vendor: Elastic Path Software Inc.
homepage: https://github.com/elasticpath/epcc-cli
maintainer: Release Engineering <rel-eng@elasticpath.com>
@@ -68,7 +66,7 @@ signs:
# If you want to manually examine the release before its live, uncomment this line:
# draft: true
changelog:
skip: false
disable: false


# .goreleaser.yaml
@@ -109,4 +107,4 @@ announce:
#
# Attention: goreleaser doesn't check the full structure of the Slack API: please make sure that
# your configuration for advanced message formatting abides by this API.
#attachments: []
#attachments: []
Loading