Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cli: do not lose changes in esc env edit when the result is invalid #27

Closed
pgavlin opened this issue Oct 4, 2023 · 0 comments · Fixed by #42
Closed

cli: do not lose changes in esc env edit when the result is invalid #27

pgavlin opened this issue Oct 4, 2023 · 0 comments · Fixed by #42
Assignees
Labels
kind/enhancement Improvements or new features needs-triage Needs attention from the triage team resolution/fixed This issue was fixed
Milestone

Comments

@pgavlin
Copy link
Member

pgavlin commented Oct 4, 2023

esc env edit loses changes if the new environment definition is not valid. This is bad. A simple approach to fixing this would be to retain the temporary file used for the edits and reopen it after displaying errors if the new definition is not valid.

@pgavlin pgavlin added kind/enhancement Improvements or new features needs-triage Needs attention from the triage team labels Oct 4, 2023
pgavlin added a commit that referenced this issue Oct 5, 2023
- Do not lose edits when the new YAML contains errors
- Automatically append "-w" to the editor if it is `code`
- Default to `vi` if no other editor is present
- Fix the help text to remove the term 'open'

Fixes #25.
Fixes #27.
@pulumi-bot pulumi-bot added the resolution/fixed This issue was fixed label Oct 5, 2023
@cleverguy25 cleverguy25 added this to the 0.95 milestone Oct 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement Improvements or new features needs-triage Needs attention from the triage team resolution/fixed This issue was fixed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants