Gentoo Archives: gentoo-user

From: Alan McKinnon <alan.mckinnon@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] kdm & french keyboard
Date: Wed, 14 Jul 2010 20:33:16
Message-Id: 201007142229.44129.alan.mckinnon@gmail.com
In Reply to: Re: [gentoo-user] kdm & french keyboard by Dale
1 On Wednesday 14 July 2010 22:12:32 Dale wrote:
2 > Alan McKinnon wrote:
3 > > On Wednesday 14 July 2010 09:58:02 Stéphane Guedon wrote:
4 > >> I agree with you, but I like to make things in order with the rules
5 > >> (without relation to udev).
6 > >>
7 > >> But I don't like udev, its syntax is really hard to understand for user
8 > >> !
9 > >
10 > > Dale, here's your chance to jump in and comment.
11 > >
12 > > This user *obviously* never had to deal with hal.
13 >
14 > Oh crap. You mean udev uses xml config files too? Well, at least udev
15 > hasn't broke my keyboard and mouse. lol I don't have to much trouble
16 > with udev. Heck, the one time I did, I deleted all the config files and
17 > re-emerged the thing. Worked great then. I think one got messed up
18 > somehow.
19 >
20 > Dale
21 >
22 > :-) :-)
23
24 No, not XML. It uses something MUCH better. It uses this:
25
26 $ cat rules.d/70-persistent-cd.rules
27 # This file was automatically generated by the /lib64/udev/write_cd_rules
28 # program, probably run by the cd-aliases-generator.rules rules file.
29 #
30 # You can modify it, as long as you keep each rule on a single line
31 # and set the $GENERATED variable.
32
33 # DVD+-RW_AD-7640A (pci-0000:00:1f.1-scsi-0:0:0:0)
34 ENV{ID_CDROM}=="?*", ENV{ID_PATH}=="pci-0000:00:1f.1-scsi-0:0:0:0",
35 SYMLINK+="cdrom", ENV{GENERATED}="1"
36 ENV{ID_CDROM}=="?*", ENV{ID_PATH}=="pci-0000:00:1f.1-scsi-0:0:0:0",
37 SYMLINK+="cdrw", ENV{GENERATED}="1"
38 ENV{ID_CDROM}=="?*", ENV{ID_PATH}=="pci-0000:00:1f.1-scsi-0:0:0:0",
39 SYMLINK+="dvd", ENV{GENERATED}="1"
40 ENV{ID_CDROM}=="?*", ENV{ID_PATH}=="pci-0000:00:1f.1-scsi-0:0:0:0",
41 SYMLINK+="dvdrw", ENV{GENERATED}="1"
42 # Mass_Storage (pci-0000:00:1d.0-usb-0:2:1.2-scsi-0:0:0:0)
43 SUBSYSTEM=="block", ENV{ID_CDROM}=="?*",
44 ENV{ID_SERIAL}=="HUAWEI_Mass_Storage-0:0", SYMLINK+="cdrom1",
45 ENV{GENERATED}="1"
46
47
48
49 See how fantastic this is? See how this conforms to The One True (Unix) Way?
50
51 See how it looks nothing like XML (invented by a Windows user, obviously), and
52 actually looks a lot like perl with regexes?
53
54 On second thoughts, it looks nothing like perl. There aren't enough $, @ and %
55 symbols in it. But the regex bit stands.
56
57 :-)
58
59
60 --
61 alan dot mckinnon at gmail dot com

Replies

Subject Author
Re: [gentoo-user] kdm & french keyboard Dale <rdalek1967@×××××.com>
Re: [gentoo-user] kdm & french keyboard "Stéphane Guedon" <stephane@××××××××××.eu>
Re: [gentoo-user] kdm & french keyboard "Stéphane Guedon" <stephane@××××××××××.eu>