Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

cli: Introduce an editor class for in-terminal edits, add waypoint runner profile edit command #4594

Merged
merged 10 commits into from
Mar 30, 2023

Conversation

briancain
Copy link
Member

@briancain briancain commented Mar 27, 2023

This commit brings in a basic Editor set of functionality to allow
various CLI commands to directly editor HCL configs rather than
requiring lots of CLI flags. Commands can launch their own editor, which
will place a temp file on disk, and return the resulting edited bytes
back to be saved or submitted as the updated config

Additionally, this pull request implements this new editor class by introducing
a new command waypoint runner profile edit where you can edit a runner
profiles plugin config directly in your editor without having to pass through
an existing config file on disk.

Fixes #4427

This commit brings in a basic Editor set of functionality to allow
various CLI commands to directly editor HCL configs rather than
requiring lots of CLI flags. Commands can launch their own editor, which
will place a temp file on disk, and return the resulting edited bytes
back to be saved or submitted as the updated config
This command makes use of the new editor package, and will edit configs
in place and submit that config up to the server.
@briancain briancain added pr/no-changelog No automatic changelog entry required for this pull request backport/0.11.x labels Mar 27, 2023
@briancain briancain requested a review from a team as a code owner March 27, 2023 21:08
@briancain briancain requested a review from a team March 27, 2023 21:08
@briancain briancain removed the pr/no-changelog No automatic changelog entry required for this pull request label Mar 27, 2023
internal/cli/editor/editor.go Outdated Show resolved Hide resolved
Copy link
Contributor

@paladin-devops paladin-devops left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Waypoint <cmd> Edit
3 participants