Skip to content

fix: replace raw echo with output helpers in general/ssh-key-mgr#683

Merged
credfeto merged 1 commit into
mainfrom
fix/637-replace-echo-with-output-helpers-in-ssh-key-mgr
Jun 15, 2026
Merged

fix: replace raw echo with output helpers in general/ssh-key-mgr#683
credfeto merged 1 commit into
mainfrom
fix/637-replace-echo-with-output-helpers-in-ssh-key-mgr

Conversation

@github-actions

@github-actions github-actions Bot commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Replaces the non-standard die() with the canonical implementation (TTY-aware coloured output to stderr, exits non-zero)
  • Adds success() and info() helpers alongside die()
  • Replaces all user-facing echo calls with info (progress messages, audit output, warnings)
  • Converts the help block from multiple echo calls to a single cat <<EOF heredoc
  • Fixes pre-existing shellcheck SC2236 warnings: [ ! -z ... ][ -n ... ]
  • Preserves echo calls that write to the SSH config file and those used as function return values via command substitution

Closes #637

Replaces the non-standard die() implementation and all user-facing raw
echo calls with the standard die/info/success helpers. The config file
writes (echo calls that redirect to SSH config) and function return
values (echo calls captured via command substitution) are preserved
unchanged. The help block is converted to a heredoc. Also fixes
pre-existing shellcheck SC2236 warnings (! -z → -n).

Closes #637

Prompt: Work on issue #637 in credfeto/scripts.
@github-actions github-actions Bot added the auto-pr Pull request created automatically label Jun 15, 2026
@dnyw4l3n13 dnyw4l3n13 added AI-Work Work for an AI Agent Urgent Urgent Priority labels Jun 15, 2026
@credfeto

Copy link
Copy Markdown
Owner

Super-linter summary

Language Validation result
BASH Pass ✅

All files and directories linted successfully

For more information, see the GitHub Actions workflow run

Powered by Super-linter

@dnyw4l3n13

Copy link
Copy Markdown
Collaborator

All CI checks have passed. The implementation has been reviewed and is complete:

  • die(), success(), and info() helpers match the canonical implementations from shell-scripts.examples.md
  • All user-facing echo calls replaced with appropriate helpers (info for progress/audit output)
  • Help block converted to a single cat <<EOF heredoc
  • Pre-existing shellcheck SC2236 warnings fixed ([ ! -z ... ][ -n ... ])
  • echo calls writing to the SSH config file and those used as function return values preserved correctly

PR is ready for review.

@credfeto credfeto enabled auto-merge June 15, 2026 13:17
@credfeto credfeto merged commit 97bc997 into main Jun 15, 2026
39 checks passed
@credfeto credfeto deleted the fix/637-replace-echo-with-output-helpers-in-ssh-key-mgr branch June 15, 2026 13:17
@credfeto

Copy link
Copy Markdown
Owner

Super-linter summary

Language Validation result

All files and directories linted successfully

For more information, see the GitHub Actions workflow run

Powered by Super-linter

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AI-Work Work for an AI Agent auto-pr Pull request created automatically Urgent Urgent Priority

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Replace raw echo with output helpers in general/ssh-key-mgr

2 participants