Skip to content

Commit 1306109

Browse files
trim ingress host (#197)
1 parent 3136b68 commit 1306109

File tree

4 files changed

+10
-5
lines changed

4 files changed

+10
-5
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
VERSION=v0.0.177
1+
VERSION=v0.0.178
22

33
OUT_DIR=dist
44
YEAR?=$(shell date +"%Y")

cmd/commands/common.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ import (
3434
"fmt"
3535
"os"
3636
"regexp"
37+
"strings"
3738

3839
"github.com/Masterminds/semver/v3"
3940
"github.com/argoproj-labs/argocd-autopilot/pkg/git"
@@ -332,6 +333,7 @@ func getKubeContextNameFromUserSelect(cmd *cobra.Command, kubeContextName *strin
332333

333334
func getIngressHostFromUserInput(cmd *cobra.Command, ingressHost *string) error {
334335
if ingressHost != nil && *ingressHost != "" {
336+
*ingressHost = strings.TrimSpace(*ingressHost)
335337
return nil
336338
}
337339

@@ -346,7 +348,10 @@ func getIngressHostFromUserInput(cmd *cobra.Command, ingressHost *string) error
346348
ingressHostInput, err := ingressHostPrompt.Run()
347349
if err != nil {
348350
return fmt.Errorf("Prompt error: %w", err)
349-
} else if ingressHostInput == "" {
351+
}
352+
353+
ingressHostInput = strings.TrimSpace(ingressHostInput)
354+
if ingressHostInput == "" {
350355
return fmt.Errorf("missing ingress host")
351356
}
352357

docs/releases/release_notes.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ cf version
2323

2424
```bash
2525
# download and extract the binary
26-
curl -L --output - https://github.com/codefresh-io/cli-v2/releases/download/v0.0.177/cf-linux-amd64.tar.gz | tar zx
26+
curl -L --output - https://github.com/codefresh-io/cli-v2/releases/download/v0.0.178/cf-linux-amd64.tar.gz | tar zx
2727

2828
# move the binary to your $PATH
2929
mv ./cf-linux-amd64 /usr/local/bin/cf
@@ -36,7 +36,7 @@ cf version
3636

3737
```bash
3838
# download and extract the binary
39-
curl -L --output - https://github.com/codefresh-io/cli-v2/releases/download/v0.0.177/cf-darwin-amd64.tar.gz | tar zx
39+
curl -L --output - https://github.com/codefresh-io/cli-v2/releases/download/v0.0.178/cf-darwin-amd64.tar.gz | tar zx
4040

4141
# move the binary to your $PATH
4242
mv ./cf-darwin-amd64 /usr/local/bin/cf

manifests/runtime.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ metadata:
55
namespace: "{{ namespace }}"
66
spec:
77
defVersion: 1.0.0
8-
version: 0.0.177
8+
version: 0.0.178
99
bootstrapSpecifier: github.com/codefresh-io/cli-v2/manifests/argo-cd
1010
components:
1111
- name: events

0 commit comments

Comments
 (0)