diff options
author | Robert Alessi <alessi@robertalessi.net> | 2018-09-10 10:41:38 +0200 |
---|---|---|
committer | Robert Alessi <alessi@robertalessi.net> | 2018-09-10 10:41:38 +0200 |
commit | 63712843c3541afcf25bcc8f24b46de7bbc8b400 (patch) | |
tree | a9c54f91074a51314dfb48713a727498477df5a2 /x200-my.initd | |
download | courses-0.1-2.tar.gz |
initial commit0.1-2
Diffstat (limited to 'x200-my.initd')
-rw-r--r-- | x200-my.initd | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/x200-my.initd b/x200-my.initd new file mode 100644 index 0000000..9d8442d --- /dev/null +++ b/x200-my.initd | |||
@@ -0,0 +1,18 @@ | |||
1 | #!/sbin/openrc-run | ||
2 | # Copyright 2018 Robert Alessi | ||
3 | # Distributed under the terms of the GNU General Public License v2 | ||
4 | |||
5 | description="Removes whining noise from Thinkpads X200 and powers off the wifi on shutdown." | ||
6 | |||
7 | start() { | ||
8 | if [ "${RC_CMD}" = "restart" ]; | ||
9 | then | ||
10 | /usr/bin/nmcli radio all off | ||
11 | fi | ||
12 | |||
13 | /usr/bin/intel_reg write 0x00061254 0x8bb7b16dc5b6a 2>/dev/null | ||
14 | } | ||
15 | |||
16 | stop() { | ||
17 | /usr/bin/nmcli radio all off | ||
18 | } | ||