Is there a way to automatically take one or a series of screeshots to capture the entire output of a powershell command? It would be nice to be able to see the original command and / or the powershell window.
This is needed in order for a government compliance team who find comfort in that a picture is more work to alter than text output.
This New-Screenshot function looks promising but it uses print screen to save the image to the clipboard. Another method looks very promising where they capture ALL the text in the buffer $Host.UI.RawUI.GetBufferContents
.
Steps to automate
- [Done] Run
clear
- [Done] Run the command
- possibly pipe the command to
more
to see it paginated
- possibly pipe the command to
- [Done] Hit print screen for just the command window and save to a file
- Scroll down to the next page and repeat step 3 until the output has been completely captured
- Cat all the images into a single image.
- Repeat step 1 and run the next command until complete.
The other way to do it is to make the text reaaaally small to get it to fit in a single window. I'd much rather prefer the first solution but I cannot find a way to scroll a window via Powershell.