summarylogtreecommitdiffstats
path: root/lego-udev-rules.install
diff options
context:
space:
mode:
Diffstat (limited to 'lego-udev-rules.install')
-rw-r--r--lego-udev-rules.install19
1 files changed, 19 insertions, 0 deletions
diff --git a/lego-udev-rules.install b/lego-udev-rules.install
new file mode 100644
index 000000000000..b7e2a0c50732
--- /dev/null
+++ b/lego-udev-rules.install
@@ -0,0 +1,19 @@
+post_install() {
+ groupadd lego
+
+ # called explicitely as automatic reload ignores our rule because of
+ # nonexistent group 'lego'
+ udevadm control --reload-rules
+
+ echo ">>> To be able to use LEGO Mindstorms NXT without having root "
+ echo ">>> permissions you should add your user to 'lego' group and "
+ echo ">>> relogin."
+}
+
+post_upgrade() {
+ post_install
+}
+
+post_remove() {
+ groupdel lego
+}