LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-08-2014, 03:02 AM   #1
gevera
LQ Newbie
 
Registered: Dec 2013
Distribution: Fedora 22, Crunchbang 11
Posts: 21

Rep: Reputation: Disabled
Tool for automatic capturing step by step actions?


Is there some tool to automated capture of step by step actions and screenshots during some task performing on computer with Ubuntu?

P.S. Just for illustration, here is one software to capture step by step actions
 
Old 12-08-2014, 05:19 AM   #2
gevera
LQ Newbie
 
Registered: Dec 2013
Distribution: Fedora 22, Crunchbang 11
Posts: 21

Original Poster
Rep: Reputation: Disabled
All credits go to jishjib22kys from reddit

Here is a solution he made
So out of curiosity I did this. Save it to a file WITH JUST ALPHANUMERIC CHARACTERS IN THE FILE NAME, because I was lazy and it explodes in your face otherwise. Then execute it in a terminal preceeding your file name with " bash " and a space:

#! /bin/bash
capdir="/tmp/$(basename $0)/$USER/$(date +%F_%H-%M-%S)_$$";
mkdir -p $capdir;
cd $capdir || (echo ERROR; exit 1);
declare -i i;
(
for inputId in $(xinput --list |egrep -o 'id=[[:digit:]]+[[:space:]]+\[slave'|egrep -o '[[:digit:]]+'); do
xinput test $inputId &
done
# couldn't find an event for when painting has finished
# /usr/bin/xev -root & # egrep --line-buffered 'release|Configure|Unmap.+synthetic YES'
wait %+;
)|fgrep --line-buffered 'release'|while read -r event; do
timestamp="$(date +%F--%H-%M-%S)";
if [[ "$lasttimestamp" == "$timestamp" ]]; then
i+=1;
else
i=0;
lasttimestamp="$timestamp";
fi
# -quality ?
#activeWinLine=$(xprop -root | grep "_NET_ACTIVE_WINDOW(WINDOW)");
#activeWinId=${activeWinLine:40};
#if [[ -n "$activeWinId" ]]; then
# import -window "$activeWinId" -frame -border "png:$timestamp_$i.png";
#fi
#echo "#$event#";
sleep 0.1; # small delay so things can be painted
import -window root "png:$timestamp--$i.png";
#echo "#done#";
done

It captures the whole screen 100ms after each key or mouse button release and saves it in /tmp/.../.../.../*.png . Maybe we should put it on github, but I don't think it's worth for just one file. During development, I called the file " scapper ".

// edit

It needs xinput and imagemagick , both probably available in all repos of all distros.

You can find more details at original reddit post here
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Step By Step Ubuntu 13.04 (Raring Ringtail) LAMP Server Setup LXer Syndicated Linux News 0 09-12-2013 05:34 PM
LXer: Complete Step by Step Guide to Make ISO Images in Ubuntu LXer Syndicated Linux News 0 06-09-2011 03:20 PM
LXer: Step By Step Ubuntu 10.04 (Lucid Lynx) LAMP Server Setup LXer Syndicated Linux News 0 08-30-2010 11:40 AM
Step-by-Step: Making integrated Broadcome wireless adapter work with Mandrake 9.2 jmp875 Linux - Wireless Networking 16 06-30-2004 01:50 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:33 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration