summaryrefslogtreecommitdiff
authorzecke <zecke>2004-08-14 12:05:39 (UTC)
committer zecke <zecke>2004-08-14 12:05:39 (UTC)
commit3df06db9e6fd268c7d234be05b01a2303dc0f7ba (patch) (side-by-side diff)
tree6a642674a0a69729c207337e63e20b8e02f40ec4
parent7cee03c63afadac76e87e276a5ef7b1bba27847b (diff)
downloadopie-3df06db9e6fd268c7d234be05b01a2303dc0f7ba.zip
opie-3df06db9e6fd268c7d234be05b01a2303dc0f7ba.tar.gz
opie-3df06db9e6fd268c7d234be05b01a2303dc0f7ba.tar.bz2
Do not hardcode /opt/QtPalmtop but use $OPIEDIR
Diffstat (more/less context) (ignore whitespace changes)
-rwxr-xr-xnoncore/tools/opie-sh/scripts/diskfree.sh4
-rwxr-xr-xnoncore/tools/opie-sh/scripts/filesystem_mounter.sh8
-rwxr-xr-xnoncore/tools/opie-sh/scripts/hostlist.sh6
-rwxr-xr-xnoncore/tools/opie-sh/scripts/killproc.sh6
-rwxr-xr-xnoncore/tools/opie-sh/scripts/launcher_refresh.sh10
-rwxr-xr-xnoncore/tools/opie-sh/scripts/logviewer.sh8
-rwxr-xr-xnoncore/tools/opie-sh/scripts/opie-sh-ssh-askpass.sh2
-rwxr-xr-xnoncore/tools/opie-sh/scripts/opie-sh-wavelanchooser.sh4
-rwxr-xr-xnoncore/tools/opie-sh/scripts/rsyncme.sh6
-rwxr-xr-xnoncore/tools/opie-sh/scripts/service_manager.sh6
-rwxr-xr-xnoncore/tools/opie-sh/scripts/stowctrl.sh8
-rwxr-xr-xnoncore/tools/opie-sh/scripts/usbnetctrl.sh12
12 files changed, 40 insertions, 40 deletions
diff --git a/noncore/tools/opie-sh/scripts/diskfree.sh b/noncore/tools/opie-sh/scripts/diskfree.sh
index 78415e3..0f17f15 100755
--- a/noncore/tools/opie-sh/scripts/diskfree.sh
+++ b/noncore/tools/opie-sh/scripts/diskfree.sh
@@ -14,18 +14,18 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# 20020524-5 - bugfix
# 20020524-1 - initial release
-OPIE_SH=/opt/QtPalmtop/bin/opie-sh
+OPIE_SH=$OPIEDIR/bin/opie-sh
# there must be a better way to do this with sed, but i had no time
# time to look into this yet...
-( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/fsmounter.png>"
+( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/fsmounter.png>"
echo "<h3>diskfree</h3> how much space is left ?<br>"
echo "<p><table>"
df -h \
| grep -v "Mounted on" \
| sed 's/ / /g' \
diff --git a/noncore/tools/opie-sh/scripts/filesystem_mounter.sh b/noncore/tools/opie-sh/scripts/filesystem_mounter.sh
index faaf37c..ba461a1 100755
--- a/noncore/tools/opie-sh/scripts/filesystem_mounter.sh
+++ b/noncore/tools/opie-sh/scripts/filesystem_mounter.sh
@@ -19,30 +19,30 @@
# 20020519-1 - added information screen with manpage excerpt, added
# better returncode-checking
# 20020517-2 - fixed output bug
# 20020517-1 - nicer fullscreen, added about, tried icon
#
-OPIE_SH=/opt/QtPalmtop/bin/opie-sh
+OPIE_SH=$OPIEDIR/bin/opie-sh
######################################################################
# subroutines
about() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/fsmounter.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/fsmounter.png>"
echo "<h3>About</h3>"
echo "This little App should make it possible for you to "
echo "easily mount and unmount filesystems from /etc/fstab"
echo "<p>"
) | $OPIE_SH -t fsmounter -f &
SCREENCLEAN=$!
sleep 1
}
beforemount() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/fsmounter.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/fsmounter.png>"
echo "<h3>mount or unmount $MOUNTPOINT ?</h3>"
echo "<b>excerpt from MOUNT(8) manpage:</b><p>"
echo "All files accessible in a Unix system are arranged in one
big tree, the file hierarchy, rooted at <b>/</b>. These files
can be spread out over several devices. The <b>mount</b> command
serves to attach the file system found on some device to
@@ -97,13 +97,13 @@ beforemount
get_action
if [ "$MOUNTPOINT" = "" ]
then echo "ugly error...." | $OPIE_SH -f ; cleanup
fi
-( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/fsmounter.png>"
+( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/fsmounter.png>"
echo "<h3>Output of $ACTION $MOUNTPOINT :</h3>"
echo "<pre>"
$ACTION $MOUNTPOINT 2>&1
echo "</pre><p>"
echo "<h3>diskfree</h3> how much space is left ?<br>"
echo "<p><table>"
diff --git a/noncore/tools/opie-sh/scripts/hostlist.sh b/noncore/tools/opie-sh/scripts/hostlist.sh
index 6d70793..d7c94f8 100755
--- a/noncore/tools/opie-sh/scripts/hostlist.sh
+++ b/noncore/tools/opie-sh/scripts/hostlist.sh
@@ -15,17 +15,17 @@
# GNU General Public License for more details.
#
# 20020524-1 - icon to hostlist
# 20020517-1 - added icon, changed name in launcher
#
-CFG=/opt/QtPalmtop/share/config/hostlist.cfg
+CFG=$OPIEDIR/share/config/hostlist.cfg
OPIE_SH=opie-sh
hostlist() {
-( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/hostlist.png>"
+( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/hostlist.png>"
echo "<h3>Hostlist</h3><br>"
HOSTLIST=`cat $CFG | grep -v '#'`
for HOST in $HOSTLIST
do
PT=` ping -c 1 $HOST | grep avg|cut -d " " -f4-`
if [ "$PT" != "" ]
@@ -43,13 +43,13 @@ hostlist() {
cleanup() {
kill $SCREENCLEAN
rm -f /tmp/qcop-msg-hostlist.sh
}
about() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/hostlist.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/hostlist.png>"
echo "<h3>About</h3>"
echo "This little App should make it possible for you to "
echo "check some hosts for availability."
echo "<p>"
) | $OPIE_SH -t hostlist -f &
SCREENCLEAN=$!
diff --git a/noncore/tools/opie-sh/scripts/killproc.sh b/noncore/tools/opie-sh/scripts/killproc.sh
index 8afb4b8..6380200 100755
--- a/noncore/tools/opie-sh/scripts/killproc.sh
+++ b/noncore/tools/opie-sh/scripts/killproc.sh
@@ -15,19 +15,19 @@
# GNU General Public License for more details.
#
# 20020524-1 - code optix
# 20020519-1 - added icon to output
# 20020517-1 - nicer fullscreen, added about, tried icon
-OPIE_SH=/opt/QtPalmtop/bin/opie-sh
+OPIE_SH=$OPIEDIR/bin/opie-sh
######################################################################
# subroutines
about() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/killproc.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/killproc.png>"
echo "<h3>About</h3>"
echo "This little util sends the TERM signal "
echo "to the specified process or process group. "
echo "The TERM signal will kill processes which "
echo "do not catch this signal. "
echo "<p> "
@@ -57,13 +57,13 @@ select_process() {
about
select_process
PROCESS=`echo $PROCESS | cut -b -4`
-( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/killproc.png>"
+( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/killproc.png>"
echo "<h3>Output of kill $PROCESS</h3>"
echo "<pre>"
kill $PROCESS 2>&1
echo "</pre><p>"
echo done.
) | $OPIE_SH -f
diff --git a/noncore/tools/opie-sh/scripts/launcher_refresh.sh b/noncore/tools/opie-sh/scripts/launcher_refresh.sh
index 7850508..c3b0617 100755
--- a/noncore/tools/opie-sh/scripts/launcher_refresh.sh
+++ b/noncore/tools/opie-sh/scripts/launcher_refresh.sh
@@ -11,16 +11,16 @@
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-OPIE_SH=opie-sh
+OPIE_SH=$OPIEDIR/bin/opie-sh
launcher_refresh() {
-( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/launcher_refresh.png>"
+( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/launcher_refresh.png>"
echo "<h3>Refresh successful!</h3><br>"
echo the launcher has been refreshed.
echo
echo this is useful if you installed packages using ipk instead of
echo oipkg. it is also helping if you are changing .desktop-files
echo often.
@@ -33,12 +33,12 @@ cleanup() {
}
#####################################################################
#
# main
-/opt/QtPalmtop/bin/qcop QPE/TaskBar "reloadInputMethods()"
-#/opt/QtPalmtop/bin/qcop QPE/System "restart()"
-/opt/QtPalmtop/bin/qcop QPE/System "linkChanged(QString)"
+$OPIEDIR/bin/qcop QPE/TaskBar "reloadInputMethods()"
+#$OPIEDIR/bin/qcop QPE/System "restart()"
+$OPIEDIR/bin/qcop QPE/System "linkChanged(QString)"
launcher_refresh
cleanup
diff --git a/noncore/tools/opie-sh/scripts/logviewer.sh b/noncore/tools/opie-sh/scripts/logviewer.sh
index e9657b4..9b5dc25 100755
--- a/noncore/tools/opie-sh/scripts/logviewer.sh
+++ b/noncore/tools/opie-sh/scripts/logviewer.sh
@@ -14,20 +14,20 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# 20020526-1a - initial release...
#
-OPIE_SH=/opt/QtPalmtop/bin/opie-sh
+OPIE_SH=$OPIEDIR/bin/opie-sh
INITPATH=/etc/init.d
######################################################################
# subroutines
about() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/logviewer.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/logviewer.png>"
echo "<h3>About</h3>"
echo "This little App should make it possible for you to "
echo "easily have a look at some of the syslogs. "
echo "<p>"
) | $OPIE_SH -t logviewer -f &
SCREENCLEAN=$!
@@ -71,26 +71,26 @@ case $LOGMETHOD in
0)
cat /proc/kmsg >/tmp/log.$$ &
PID=$!
sleep 2
kill $PID
-( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/logviewer.png>"
+( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/logviewer.png>"
echo "<h3>/proc/kmsg</h3>"
cat /tmp/log.$$
) | $OPIE_SH -t kmsg -f
rm -f /tmp/$$
cleanup ;;
1)
cat /proc/ksyms >/tmp/log.$$ &
PID=$!
sleep 2
kill $PID
-( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/logviewer.png>"
+( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/logviewer.png>"
echo "<h3>/proc/ksyms</h3>"
cat /tmp/log.$$
) | $OPIE_SH -t ksyms -f
rm -f /tmp/$$
cleanup ;;
diff --git a/noncore/tools/opie-sh/scripts/opie-sh-ssh-askpass.sh b/noncore/tools/opie-sh/scripts/opie-sh-ssh-askpass.sh
index 7e1e7ad..7d13345 100755
--- a/noncore/tools/opie-sh/scripts/opie-sh-ssh-askpass.sh
+++ b/noncore/tools/opie-sh/scripts/opie-sh-ssh-askpass.sh
@@ -1,8 +1,8 @@
#!/bin/sh
# opie-sh-ssh-askpass -- ssh-askpass utility using opie-sh
-OPIE_SH=opie-sh
+OPIE_SH=$OPIEDIR/bin/opie-sh
exec $OPIE_SH -i -p -t "OpenSSH" -g -L "<SMALL>$@" 2>/dev/null
diff --git a/noncore/tools/opie-sh/scripts/opie-sh-wavelanchooser.sh b/noncore/tools/opie-sh/scripts/opie-sh-wavelanchooser.sh
index 13a1e79..49c62c4 100755
--- a/noncore/tools/opie-sh/scripts/opie-sh-wavelanchooser.sh
+++ b/noncore/tools/opie-sh/scripts/opie-sh-wavelanchooser.sh
@@ -16,16 +16,16 @@
#
# 20020528-1 - fixed filename in cleanup
# 20020526-1 - rudimental but working
# 20020524-1 - initial working release planned
#
-OPIE_SH=opie-sh
+OPIE_SH=$OPIEDIR/bin/opie-sh
about() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/qtwavelan.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/qtwavelan.png>"
echo "<h3>About</h3>"
echo "This little App is for changing the location setting"
echo "for your wireless card. <br>"
echo "actually it only starts /etc/init.d/[home|work] and can"
echo "be easily turned into a quick program to start the service"
echo "or init script you use most."
diff --git a/noncore/tools/opie-sh/scripts/rsyncme.sh b/noncore/tools/opie-sh/scripts/rsyncme.sh
index c09aea8..3d56c12 100755
--- a/noncore/tools/opie-sh/scripts/rsyncme.sh
+++ b/noncore/tools/opie-sh/scripts/rsyncme.sh
@@ -14,14 +14,14 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# 20020517-1 - added icon, changed name in launcher
#
-CFG=/opt/QtPalmtop/share/config/rsyncme.cfg
-OPIE_SH=opie-sh
+CFG=$OPIEDIR/share/config/rsyncme.cfg
+OPIE_SH=$OPIEDIR/bin/opie-sh
update_cfg() {
# check if dir is in CFG and if not add it
if [ "`grep -c $DIR $CFG`" = "0" ]
then echo $DIR >>$CFG
fi
@@ -65,13 +65,13 @@ show_dirs() {
( echo "<h3>Directorys chosen for sync:</h3>"
echo "<ul><li>$SRCDIR<li>$DESTDIR</ul>" ) \
| $OPIE_SH -t "Got directories" -f
}
about() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/rsyncme.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/rsyncme.png>"
echo "<h3>About</h3>"
echo "This little App should make it possible for you to "
echo "easily choose the wanted options for an rsync process."
echo "<p>"
) | $OPIE_SH -t rsync-helper -f &
SCREENCLEAN=$!
diff --git a/noncore/tools/opie-sh/scripts/service_manager.sh b/noncore/tools/opie-sh/scripts/service_manager.sh
index d1423a5..e3c04bc 100755
--- a/noncore/tools/opie-sh/scripts/service_manager.sh
+++ b/noncore/tools/opie-sh/scripts/service_manager.sh
@@ -16,20 +16,20 @@
#
# 20020524-1 - added icon to statusinfo...
# 20020518-1 - optix
# 20020517-1 - added about and fullscreen
#
-OPIE_SH=/opt/QtPalmtop/bin/opie-sh
+OPIE_SH=$OPIEDIR/bin/opie-sh
INITPATH=/etc/init.d
######################################################################
# subroutines
about() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/service_manager.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/service_manager.png>"
echo "<h3>About</h3>"
echo "This little App should make it possible for you to "
echo "easily start and stop services in /etc/init.d."
echo "<p>"
) | $OPIE_SH -t service-manager -f &
SCREENCLEAN=$!
@@ -59,13 +59,13 @@ get_action() {
}
status_disclaimer() {
# tell that init scripts are not too standard
#
cat | $OPIE_SH -f <<EOT
-<img src=/opt/QtPalmtop/pics/opie-sh-scripts/service_manager.png>
+<img src=$OPIEDIR/pics/opie-sh-scripts/service_manager.png>
<h3>status has been disabled</h3>
the status service has been disabled
because it is not supported by the
most init scripts that come with
familiar ...<p>
diff --git a/noncore/tools/opie-sh/scripts/stowctrl.sh b/noncore/tools/opie-sh/scripts/stowctrl.sh
index 475c3a3..20cb6ae 100755
--- a/noncore/tools/opie-sh/scripts/stowctrl.sh
+++ b/noncore/tools/opie-sh/scripts/stowctrl.sh
@@ -16,40 +16,40 @@
# GNU General Public License for more details.
#
# 20020524-1 - code beautification, added icons and reset
# 20020517-2 - bugfixed fullscreen, added info about ifconfig
# 20020517-1 - added about, fullscreen and icon
-OPIE_SH=/opt/QtPalmtop/bin/opie-sh
+OPIE_SH=$OPIEDIR/bin/opie-sh
######################################################################
# subroutines
about() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/stowctrl.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/stowctrl.png>"
echo "<h3>About</h3>"
echo "This little App should make it easy for you to "
echo "activate / deactivate the stowaway keyboard (on ipaq)"
echo "<p>"
) | $OPIE_SH -t "stowaway control" -f &
SCREENCLEAN=$!
sleep 1
}
startup() {
- echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/stowctrl.png>" > /tmp/sout
+ echo "<img src=$OPIEDIR/pics/opie-sh-scripts/stowctrl.png>" > /tmp/sout
echo "<h3>stowaway up</h3>" >> /tmp/sout
modprobe h3600_stowaway >> /tmp/sout
cat /dev/stowaway &
echo $! > /tmp/stowcatpid
$OPIE_SH -t Output -f /tmp/sout
rm /tmp/sout
}
stopit() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/stowctrl.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/stowctrl.png>"
echo "<h3>stowaway down</h3>"
read THECAT < /tmp/stowcatpid
kill $THECAT
rmmod h3600_stowaway
) 2>&1 | $OPIE_SH -t Output -f
}
diff --git a/noncore/tools/opie-sh/scripts/usbnetctrl.sh b/noncore/tools/opie-sh/scripts/usbnetctrl.sh
index 417435e..af68a3d 100755
--- a/noncore/tools/opie-sh/scripts/usbnetctrl.sh
+++ b/noncore/tools/opie-sh/scripts/usbnetctrl.sh
@@ -15,50 +15,50 @@
# GNU General Public License for more details.
#
# 20020524-1 - code beautification, added icons and reset
# 20020517-2 - bugfixed fullscreen, added info about ifconfig
# 20020517-1 - added about, fullscreen and icon
-OPIE_SH=/opt/QtPalmtop/bin/opie-sh
+OPIE_SH=$OPIEDIR/bin/opie-sh
######################################################################
# subroutines
about() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/usbnetctrl.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/usbnetctrl.png>"
echo "<h3>About</h3>"
echo "This little App should make it easy for you to "
echo "activate / deactivate the usbnet-driver (on ipaq)"
echo "<p>"
echo "To use it at first, you need to change the ifconfig"
- echo "line in /opt/QtPalmtop/bin/usbnetctrl.sh."
+ echo "line in $OPIEDIR/bin/usbnetctrl.sh."
) | $OPIE_SH -t "usbnet control" -f &
SCREENCLEAN=$!
sleep 1
}
startup() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/usbnetctrl.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/usbnetctrl.png>"
echo "<h3>usbnet up</h3>"
modprobe usb-eth
) 2>&1 | $OPIE_SH -t Output -f
$OPIE_SH -m -I -t "Usbnet Control" -M "Please connect the<br>ipaq to the cradle<br>and press OK"
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/usbnetctrl.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/usbnetctrl.png>"
echo "<h3>usbnet up</h3>"
ifconfig usbf up 192.168.0.1 netmask 255.255.255.0
) 2>&1 | $OPIE_SH -t Output -f
if [ -f /root/masq.sh ]
then sh /root/masq.sh
fi
}
stopit() {
- ( echo "<img src=/opt/QtPalmtop/pics/opie-sh-scripts/usbnetctrl.png>"
+ ( echo "<img src=$OPIEDIR/pics/opie-sh-scripts/usbnetctrl.png>"
echo "<h3>usbnet down</h3>"
ifconfig usbf down
sleep 1
rmmod usb-eth
rmmod sa1100usb_core
) 2>&1 | $OPIE_SH -t Output -f