Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Wed 03 Sep 2014, 03:32
All times are UTC - 4
 Forum index » Taking the Puppy out for a walk » Suggestions
Can we load sfs or pet from script ?
Moderators: Flash, Ian, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [6 Posts]  
Author Message
Master_wrong

Joined: 19 Mar 2008
Posts: 456

PostPosted: Mon 02 Jan 2012, 00:43    Post subject:  Can we load sfs or pet from script ?  

here what i want to do...

1. create a folder " load-this"
2. create script to seek folder "load-this" and mount or install all pet or sfs in there

is it possible for me to do it ?


thank you

_________________
Cluster-Pup v.2-Puppy Beowulf Cluster
http://www.murga-linux.com/puppy/viewtopic.php?p=499199#499199
Back to top
View user's profile Send private message 
shinobar


Joined: 28 May 2009
Posts: 2618
Location: Japan

PostPosted: Mon 02 Jan 2012, 03:48    Post subject: Re: Can we load sfs or pet from script ?  

# sfs_load SOMETHING.sfs
# petget SOMETHING.pet

_________________
Google Chrome portable
Downloads for Puppy Linux http://shino.pos.to/linux/downloads.html
Back to top
View user's profile Send private message Visit poster's website 
Jasper


Joined: 25 Apr 2010
Posts: 1111
Location: England

PostPosted: Mon 02 Jan 2012, 06:40    Post subject:  

Hi Master_wrong,

I am not sure that I entirely understand your request or shinobar's reply.

See http://www.murga-linux.com/puppy/viewtopic.php?t=74471 to use seaside's program which loads all sfs files in any specified directory in a single operation.

I have an unusual use in mind if you are able to install all the pets in a single directory using a single command. If shinobar has not already done it, I suspect it would take him, or any expert, only a few seconds to do it.

My regards
Back to top
View user's profile Send private message 
sc0ttman


Joined: 16 Sep 2009
Posts: 2376
Location: UK

PostPosted: Mon 02 Jan 2012, 07:14    Post subject: Re: Can we load sfs or pet from script ?  

shinobar wrote:
# sfs_load SOMETHING.sfs
# petget SOMETHING.pet


OR

Code:
#!/bin/sh
for x in /path/to/folder/*
do
  ext=${x##*.} # extension only
  [ "$ext" = "pet" ] && petget $x
  [ "$ext" = "sfs" ] && sfs_load $x
done

_________________
Akita Linux, VLC-GTK, Pup Search, Pup File Search
Back to top
View user's profile Send private message 
Master_wrong

Joined: 19 Mar 2008
Posts: 456

PostPosted: Mon 02 Jan 2012, 09:33    Post subject:  

Hi,
Very Happy
Thanks all for the reply, ok i try all the suggestion...

btw...
HAPPY NEW YEAR !!!

_________________
Cluster-Pup v.2-Puppy Beowulf Cluster
http://www.murga-linux.com/puppy/viewtopic.php?p=499199#499199
Back to top
View user's profile Send private message 
RSH


Joined: 05 Sep 2011
Posts: 2420
Location: Germany

PostPosted: Mon 02 Jan 2012, 11:45    Post subject: Yes, we can!
Subject description: You, as an American, should really know this...
 

Hello, Master_wrong,

and a Happy New Year.

I am sure you can do this.

I am using this in my LazY Puppy and so i can run 10 specific sfs files from the menu or similar from a gui. If i do not choose a button (sfs file) inside the gui and leave the gui by "OK" i get another gui (yad) that opens a specific directory to select one of the included files.

I can set the name of the sfs files in the LazY Puppy Preferences GUI. So i can use up to ten other sfs files rather than the pre-specified ones.

Each button or similar menu entry runs a script specially created for the wanted sfs file.

Code:
#!/bin/sh

if [ -f /usr/sbin/ceelab/lazy-sfs-load/data/sfs-list.rc ];then
    . /usr/sbin/ceelab/lazy-sfs-load/data/sfs-list.rc
fi

exec sfs_load $SFSAUDIOMIDIEDIT &


Surely "exec..." better should be placed inside "if" and "fi"

$SFSAUDIOMIDIEDIT is specified in the file sfs-list.rc.

Code:
SFSAUDIOMIDIEDIT="LazY528-Audio-Midi-Edit.sfs"
SFSMEDIAPLAYER="LazY528-AV-Player.sfs"
SFSDEVX4="LazY528-devx4.sfs"
SFSDEVX4GMB="LazY528-devx4-GMB271.sfs"
SFSGRAPHICS="LazY528-Grafik.sfs"
SFSINTERNET="LazY528-Internet.sfs"
SFSLFPC="LazY528-LZ09300-FPC242.sfs"
SFSOFFICE="LazY528-Office.sfs"
SFSTOOLS="LazY528-Tools.sfs"
SFSVIDEOEDIT="LazY528-Video-Edit.sfs"
SFSWINE="LazY528-Wine.sfs"


Hope this will be a bit of inspiring you...

RSH
direct-sfs-load-menu.jpg
 Description   
 Filesize   70.89 KB
 Viewed   413 Time(s)

direct-sfs-load-menu.jpg

direkt-sfs-load-gui.jpg
 Description   
 Filesize   47.86 KB
 Viewed   416 Time(s)

direkt-sfs-load-gui.jpg

lazy-preferences.jpg
 Description   
 Filesize   48.07 KB
 Viewed   425 Time(s)

lazy-preferences.jpg


_________________
LazY Puppy
RSH's DNA
SARA B.
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [6 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Taking the Puppy out for a walk » Suggestions
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0592s ][ Queries: 12 (0.0056s) ][ GZIP on ]