corz.org text viewer..
[currently viewing: /public/linux/usr/local/bin/scr.sh - raw]
#!/bin/bash
#
#  capture a screenshot..
#
#        usage:
#        scr [output filename (optional)]
#    
#        note:    if a filename isn't specified, scr defaults to ~/screenshot.raw
#                which is a file called "screenshot.raw" in your home folder
#
#  the screen capture is saved as a three channel (RGB) interleaved 
#  bitmap image with BGR ordering and a 0 byte header.
#
#  have fun!
#
#  ;o)
#  (or @ corz.org 2005
#

if [ "$1" = '-h' ]; then echo; echo "usage: src [<output filename>]"; echo; exit; fi
if [ "$1" = '' ]; then out=~/screenshot.raw; else out=$1; fi

cat /dev/fb0 > ${out}

echo
echo "screenshot saved to $out"
echo

Welcome to corz.org!

Since switching hosts (I hope you are alright, Ed! Wherever you are …) quite a few things seems to be wonky.

Juggling two energetic boys (of very different ages) on Coronavirus lockdown, I'm unlikely to have them all fixed any time soon. Mail me! to prioritise!