You are not logged in.

#1 2009-04-24 02:22:34

lolilolicon
Member
Registered: 2009-03-05
Posts: 1,722

want Female Human Being fit in ya thirsty plastic monitor ? :P

Really Simple Script Here For Ur Wall , enjoy!

#!/bin/bash
if [ -z "$1"  ] || [ -z "$2" ]
then
        echo "***** USAGE  ::  $0  A  B *****"
        echo "***** A :: page number to start with *****"
        echo "***** B :: page number to stop  upon *****"
exit
fi
#replace 1280x800 (note it appears twice in this script below, line 9 AND 15) with your screen resolution
DIR=$HOME/BG/skin.be
URLFILE=$DIR/urls

INDEX=$1   #page number to start with
LIM=$2   #page number to stop upon
let COUNT="$LIM"-"$INDEX"+1
SIZE=1280x800

while [ "$INDEX" -le "$LIM" ]
do
tput sc
echo -n "***** COUNTING DOWN :: $COUNT *****"
##get pic url
curl -s http://www.skins.be/tags/$SIZE/page/$INDEX/ | awk -F \" '/betathumbnails/{ gsub(/betathumbnails/,"wallpapers");print $4 }'| awk -F '-' '{gsub($NF,"1280x800-"$NF);print}' >> $URLFILE
((INDEX++))
((COUNT--))
tput el1;tput rc
done

## image downloading starts
aria2c -d $DIR -i $URLFILE
mv $URLFILE "$URLFILE"_"$1"_"$2"

Last edited by lolilolicon (2009-04-24 04:54:41)


This silver ladybug at line 28...

Offline

#2 2009-04-24 03:01:56

dr/owned
Member
Registered: 2009-01-09
Posts: 136

Re: want Female Human Being fit in ya thirsty plastic monitor ? :P

Why do I get the gnawing feeling something in this code will brick the OS?

Offline

#3 2009-04-24 03:12:36

ShadowKyogre
Member
From: Hell! XP No... I'm not telling
Registered: 2008-12-19
Posts: 476
Website

Re: want Female Human Being fit in ya thirsty plastic monitor ? :P

I don't know, best try on a LiveCD first.


For every problem, there is a solution that is:
Clean
Simple and most of all...wrong!
Github page

Offline

#4 2009-04-24 03:13:27

lolilolicon
Member
Registered: 2009-03-05
Posts: 1,722

Re: want Female Human Being fit in ya thirsty plastic monitor ? :P

dr/owned wrote:

Why do I get the gnawing feeling something in this code will brick the OS?

LIKELY

IT IS A BRICK wink


This silver ladybug at line 28...

Offline

#5 2009-04-24 03:14:03

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: want Female Human Being fit in ya thirsty plastic monitor ? :P

dr/owned wrote:

Why do I get the gnawing feeling something in this code will brick the OS?

Codophobia?

The script looks harmless to me.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#6 2009-04-24 03:30:17

HashBox
Member
Registered: 2009-01-22
Posts: 271

Re: want Female Human Being fit in ya thirsty plastic monitor ? :P

The only thing that caught my attention was tput, and it looks as though that's there to control the way the terminal behaves for the countdown code. Looks like a nice little script smile

Offline

#7 2009-04-24 03:48:25

Lux Perpetua
Member
From: The Local Group
Registered: 2009-02-22
Posts: 69

Re: want Female Human Being fit in ya thirsty plastic monitor ? :P

dr/owned wrote:

Why do I get the gnawing feeling something in this code will brick the OS?

Don't run scripts as root, and your Linux is generally safe from brickhood.

Offline

#8 2009-04-24 04:06:58

lolilolicon
Member
Registered: 2009-03-05
Posts: 1,722

Re: want Female Human Being fit in ya thirsty plastic monitor ? :P

HashBox wrote:

The only thing that caught my attention was tput, and it looks as though that's there to control the way the terminal behaves for the countdown code. Looks like a nice little script smile

Thanks,HashBox
the tput little trick is what i've just got from Mr. Google back yesterday.

tput sc   #Save the cursor position
echo -n "blablabla"
tput el1  #Clear to beginning of line
tput rc   #Restore the cursor position


Well, the script is for practical purpose only!! no scripting technique included ....

Last edited by lolilolicon (2009-04-24 04:11:00)


This silver ladybug at line 28...

Offline

#9 2009-04-24 04:48:35

HashBox
Member
Registered: 2009-01-22
Posts: 271

Re: want Female Human Being fit in ya thirsty plastic monitor ? :P

Nice use of that, I looked it up (tput) after I posted and saw that's what it was doing smile handy trick to remember.

Offline

#10 2009-04-24 21:23:51

dr/owned
Member
Registered: 2009-01-09
Posts: 136

Re: want Female Human Being fit in ya thirsty plastic monitor ? :P

Paranoia keeps me safe big_smile

Offline

#11 2009-04-25 09:17:20

droog
Member
Registered: 2004-11-18
Posts: 877

Re: want Female Human Being fit in ya thirsty plastic monitor ? :P

Yes My Thirsty Plstic Moniter Was Thirsty For Human Being Fit.

Thanks For Fiklling Sc Rtpt!!!

Offline

Board footer

Powered by FluxBB