source: udev/cdsymlink_helper.sh @ f0da65f

clfs-1.2clfs-2.1clfs-3.0.0-systemdclfs-3.0.0-sysvinitsystemdsysvinit
Last change on this file since f0da65f was f0da65f, checked in by Jim Gifford <clfs@…>, 18 years ago

r3468@server: jim | 2006-05-14 11:39:43 -0700
Updates to udev cdsymlink_helper.sh

  • Property mode set to 100755
File size: 726 bytes
RevLine 
[93a4751]1#!/bin/sh
2########################################################################
3#
4# Description : cdsymlink_helper.sh
5#
6# Authors     : Jim Gifford
7#
8# Version     : 00.00
9#
10# Notes       :
11#
12########################################################################
13
14. /lib/udev/helper.functions
15. /etc/sysconfig/udev_helper
16
17KERN_NAME="$1"
18
19if [ "$KERN_NAME" = "" ]; then
20        mesg Bad invocation: \$1 is not set
21        exit 1
22fi
[f0da65f]23echo "here" > /tmp/cdrom
24FILES="`ls /sys/bus/ide/drivers/ide-cdrom | grep 1.`"
25        for file in $FILES; do
26                TEST="`ls /sys/bus/ide/drivers/ide-cdrom/$file | grep -c $KERN_NAME`"
27                if [ "$TEST" = "1" ]; then
28                        link="`echo $file | cut -f2 -d.`"
29                        echo $link
30                        echo "link = $link" >> /tmp/cdrom
[93a4751]31                fi
[f0da65f]32        done
Note: See TracBrowser for help on using the repository browser.