Summary: | Add a command-line option to save buffer as HTML | ||
---|---|---|---|
Product: | [Applications] konsole | Reporter: | Christopher Yeleighton <giecrilj> |
Component: | general | Assignee: | Konsole Developer <konsole-devel> |
Status: | REPORTED --- | ||
Severity: | wishlist | CC: | ninjalj |
Priority: | NOR | ||
Version: | 21.04.2 | ||
Target Milestone: | --- | ||
Platform: | openSUSE | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: |
Description
Christopher Yeleighton
2021-06-19 08:03:50 UTC
A workaround using xdotool: konsole -e 'sh -c "rm ~/colors.html; cat ~/colors.txt; xdotool key ctrl+S; sleep 1; xdotool type ~/colors.html; sleep 1; xdotool key Return; sleep 1"' This workaround uses xdotool to invoke the "Save Output As..." menu, then writes the filename, and sends a Return key to invoke the default "Save" button. The "sleep"s are important. They let the previous action complete before invoking another action. The last one prevents Konsole from exiting before it has completed the save action. (In reply to ninjalj from comment #1) > A workaround using xdotool: > > konsole -e 'sh -c "rm ~/colors.html; cat ~/colors.txt; xdotool key ctrl+S; > sleep 1; xdotool type ~/colors.html; sleep 1; xdotool key Return; sleep 1"' > > This workaround uses xdotool to invoke the "Save Output As..." menu, then > writes the filename, and sends a Return key to invoke the default "Save" > button. > > The "sleep"s are important. They let the previous action complete before > invoking another action. The last one prevents Konsole from exiting before > it has completed the save action. This workaround requires starting a separate display, I am afraid. |