3 ms·
So for those who want the tl;dr: The answer is just "use a udev rule". Udev is one of those classic open source tools that is immensely powerful and gracefully
by ajross 1y ago
So for those who want the tl;dr: The answer is just "use a udev rule".
Udev is one of those classic open source tools that is immensely powerful and gracefully well designed, with all sorts of emergent power...
...that ends up being an obscure bit of graybeard prestidigitation purely because of it's awful syntax.
No really, there's a very clean mapping between the state in sysfs and the resulting uevents produced. You just can't tell because of the way it looks.
- M95D 1y agoIf you don't like udev (and I don't blame you, I hate it too), you can do the exact same thing with mdev or acpid.
- ajross 1y agoOh, I like udev! I'm just sad that so few people know anything about how sysfs/uevents/udev work, because it seems so ugly and arcane when you're exposed to your first udev rule.
- M95D 1y ago> I'm just sad that so few people know anything about how sysfs/uevents/udev work Here's the opportunity to write a blog post about it.