Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- #read -p "Number of pages: " num
- #https://issuu.com/
- #Amazon.com
- sleep 3;
- #get page1 crop info
- import /tmp/out.png
- size="$(identify /tmp/out.png |cut -d\ -f3)"
- offset="+$(identify /tmp/out.png |cut -d\+ -f2,3|awk '{print $1}')"
- page1="${size}${offset}"
- echo "$page1"
- #get page2 crop info
- import /tmp/out.png
- size="$(identify /tmp/out.png |cut -d\ -f3)"
- offset="+$(identify /tmp/out.png |cut -d\+ -f2,3|awk '{print $1}')"
- page2="${size}${offset}"
- echo "$page2"
- sleep 5
- for page in {01..1000}
- do
- echo "$page"
- sleep 1
- import -window root +repage -crop $page1 $(date +%s).jpg
- sleep 1
- import -window root +repage -crop $page2 $(date +%s).jpg
- xte "mouseclick 1"
- done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement