git: update smtpuser, set transfer.fsckObjects
[~bandali/configs] / rc.org
1 #+title: rc.org
2 #+property: header-args :comments link :mkdirp yes :results silent
3
4 * About
5
6 This org file contains the configuration files of pretty much every
7 program I use. The files are tangled (i.e. exported, or derived) from
8 this file using =org-babel=.
9
10 Note: This file is best viewed inside Emacs with org mode.
11
12 * Configs
13
14 This section contains the configuration files (dotfiles) of various
15 programs I use.
16
17 ** mpd
18 :PROPERTIES:
19 :header-args+: :tangle ~/.config/mpd/mpd.conf
20 :END:
21
22 #+begin_src conf
23 # An example configuration file for MPD.
24 # Read the user manual for documentation: http://www.musicpd.org/doc/user/
25
26
27 # Files and directories #######################################################
28 #
29 # This setting controls the top directory which MPD will search to discover the
30 # available audio files and add them to the daemon's online database. This
31 # setting defaults to the XDG directory, otherwise the music directory will be
32 # be disabled and audio files will only be accepted over ipc socket (using
33 # file:// protocol) or streaming files over an accepted protocol.
34 #
35 music_directory "~/usr/music"
36 #
37 # This setting sets the MPD internal playlist directory. The purpose of this
38 # directory is storage for playlists created by MPD. The server will use
39 # playlist files not created by the server but only if they are in the MPD
40 # format. This setting defaults to playlist saving being disabled.
41 #
42 playlist_directory "~/.mpd/playlists"
43 #
44 # This setting sets the location of the MPD database. This file is used to
45 # load the database at server start up and store the database while the
46 # server is not up. This setting defaults to disabled which will allow
47 # MPD to accept files over ipc socket (using file:// protocol) or streaming
48 # files over an accepted protocol.
49 #
50 db_file "~/.mpd/database"
51 #
52 # These settings are the locations for the daemon log files for the daemon.
53 # These logs are great for troubleshooting, depending on your log_level
54 # settings.
55 #
56 # The special value "syslog" makes MPD use the local syslog daemon. This
57 # setting defaults to logging to syslog, otherwise logging is disabled.
58 #
59 log_file "~/.mpd/log"
60 #
61 # This setting sets the location of the file which stores the process ID
62 # for use of mpd --kill and some init scripts. This setting is disabled by
63 # default and the pid file will not be stored.
64 #
65 pid_file "~/.mpd/pid"
66 #
67 # This setting sets the location of the file which contains information about
68 # most variables to get MPD back into the same general shape it was in before
69 # it was brought down. This setting is disabled by default and the server
70 # state will be reset on server start up.
71 #
72 state_file "~/.mpd/state"
73 #
74 # The location of the sticker database. This is a database which
75 # manages dynamic information attached to songs.
76 #
77 sticker_file "~/.mpd/sticker.sql"
78 #
79 ###############################################################################
80
81
82 # General music daemon options ################################################
83 #
84 # This setting specifies the user that MPD will run as. MPD should never run as
85 # root and you may use this setting to make MPD change its user ID after
86 # initialization. This setting is disabled by default and MPD is run as the
87 # current user.
88 #
89 #user "nobody"
90 #
91 # This setting specifies the group that MPD will run as. If not specified
92 # primary group of user specified with "user" setting will be used (if set).
93 # This is useful if MPD needs to be a member of group such as "audio" to
94 # have permission to use sound card.
95 #
96 #group "nogroup"
97 #
98 # This setting sets the address for the daemon to listen on. Careful attention
99 # should be paid if this is assigned to anything other then the default, any.
100 # This setting can deny access to control of the daemon. Not effective if
101 # systemd socket activiation is in use.
102 #
103 # For network
104 #bind_to_address "any"
105 #
106 # And for Unix Socket
107 #bind_to_address "~/.mpd/socket"
108 #
109 # This setting is the TCP port that is desired for the daemon to get assigned
110 # to.
111 #
112 #port "6600"
113 #
114 # This setting controls the type of information which is logged. Available
115 # setting arguments are "default", "secure" or "verbose". The "verbose" setting
116 # argument is recommended for troubleshooting, though can quickly stretch
117 # available resources on limited hardware storage.
118 #
119 #log_level "default"
120 #
121 # If you have a problem with your MP3s ending abruptly it is recommended that
122 # you set this argument to "no" to attempt to fix the problem. If this solves
123 # the problem, it is highly recommended to fix the MP3 files with vbrfix
124 # (available from <http://www.willwap.co.uk/Programs/vbrfix.php>), at which
125 # point gapless MP3 playback can be enabled.
126 #
127 #gapless_mp3_playback "yes"
128 #
129 # Setting "restore_paused" to "yes" puts MPD into pause mode instead
130 # of starting playback after startup.
131 #
132 #restore_paused "no"
133 #
134 # This setting enables MPD to create playlists in a format usable by other
135 # music players.
136 #
137 #save_absolute_paths_in_playlists "no"
138 #
139 # This setting defines a list of tag types that will be extracted during the
140 # audio file discovery process. The complete list of possible values can be
141 # found in the user manual.
142 #metadata_to_use "artist,album,title,track,name,genre,date,composer,performer,disc"
143 #
144 # This setting enables automatic update of MPD's database when files in
145 # music_directory are changed.
146 #
147 #auto_update "yes"
148 #
149 # Limit the depth of the directories being watched, 0 means only watch
150 # the music directory itself. There is no limit by default.
151 #
152 #auto_update_depth "3"
153 #
154 ###############################################################################
155
156
157 # Symbolic link behavior ######################################################
158 #
159 # If this setting is set to "yes", MPD will discover audio files by following
160 # symbolic links outside of the configured music_directory.
161 #
162 #follow_outside_symlinks "yes"
163 #
164 # If this setting is set to "yes", MPD will discover audio files by following
165 # symbolic links inside of the configured music_directory.
166 #
167 #follow_inside_symlinks "yes"
168 #
169 ###############################################################################
170
171
172 # Zeroconf / Avahi Service Discovery ##########################################
173 #
174 # If this setting is set to "yes", service information will be published with
175 # Zeroconf / Avahi.
176 #
177 #zeroconf_enabled "yes"
178 #
179 # The argument to this setting will be the Zeroconf / Avahi unique name for
180 # this MPD server on the network.
181 #
182 #zeroconf_name "Music Player"
183 #
184 ###############################################################################
185
186
187 # Permissions #################################################################
188 #
189 # If this setting is set, MPD will require password authorization. The password
190 # setting can be specified multiple times for different password profiles.
191 #
192 #password "password@read,add,control,admin"
193 #
194 # This setting specifies the permissions a user has who has not yet logged in.
195 #
196 #default_permissions "read,add,control,admin"
197 #
198 ###############################################################################
199
200
201 # Database #######################################################################
202 #
203
204 #database {
205 # plugin "proxy"
206 # host "other.mpd.host"
207 # port "6600"
208 #}
209
210 # Input #######################################################################
211 #
212
213 input {
214 plugin "curl"
215 # proxy "proxy.isp.com:8080"
216 # proxy_user "user"
217 # proxy_password "password"
218 }
219
220 #
221 ###############################################################################
222
223 # Audio Output ################################################################
224 #
225
226 audio_output {
227 type "pulse"
228 name "pulse audio"
229 }
230
231 audio_output {
232 type "fifo"
233 name "my_fifo"
234 path "/tmp/mpd.fifo"
235 format "44100:16:2"
236 }
237
238 # MPD supports various audio output types, as well as playing through multiple
239 # audio outputs at the same time, through multiple audio_output settings
240 # blocks. Setting this block is optional, though the server will only attempt
241 # autodetection for one sound card.
242 #
243 # An example of an ALSA output:
244 #
245 #audio_output {
246 # type "alsa"
247 # name "My ALSA Device"
248 ## device "hw:0,0" # optional
249 ## mixer_type "hardware" # optional
250 ## mixer_device "default" # optional
251 ## mixer_control "PCM" # optional
252 ## mixer_index "0" # optional
253 #}
254 #
255 # An example of an OSS output:
256 #
257 #audio_output {
258 # type "oss"
259 # name "My OSS Device"
260 ## device "/dev/dsp" # optional
261 ## mixer_type "hardware" # optional
262 ## mixer_device "/dev/mixer" # optional
263 ## mixer_control "PCM" # optional
264 #}
265 #
266 # An example of a shout output (for streaming to Icecast):
267 #
268 #audio_output {
269 # type "shout"
270 # encoder "vorbis" # optional
271 # name "My Shout Stream"
272 # host "localhost"
273 # port "8000"
274 # mount "/mpd.ogg"
275 # password "hackme"
276 # quality "5.0"
277 # bitrate "128"
278 # format "44100:16:1"
279 ## protocol "icecast2" # optional
280 ## user "source" # optional
281 ## description "My Stream Description" # optional
282 ## url "http://example.com" # optional
283 ## genre "jazz" # optional
284 ## public "no" # optional
285 ## timeout "2" # optional
286 ## mixer_type "software" # optional
287 #}
288 #
289 # An example of a recorder output:
290 #
291 #audio_output {
292 # type "recorder"
293 # name "My recorder"
294 # encoder "vorbis" # optional, vorbis or lame
295 # path "/var/lib/mpd/recorder/mpd.ogg"
296 ## quality "5.0" # do not define if bitrate is defined
297 # bitrate "128" # do not define if quality is defined
298 # format "44100:16:1"
299 #}
300 #
301 # An example of a httpd output (built-in HTTP streaming server):
302 #
303 #audio_output {
304 # type "httpd"
305 # name "My HTTP Stream"
306 # encoder "vorbis" # optional, vorbis or lame
307 # port "8000"
308 # bind_to_address "0.0.0.0" # optional, IPv4 or IPv6
309 ## quality "5.0" # do not define if bitrate is defined
310 # bitrate "128" # do not define if quality is defined
311 # format "44100:16:1"
312 # max_clients "0" # optional 0=no limit
313 #}
314 #
315 # An example of a pulseaudio output (streaming to a remote pulseaudio server)
316 #
317 #audio_output {
318 # type "pulse"
319 # name "My Pulse Output"
320 ## server "remote_server" # optional
321 ## sink "remote_server_sink" # optional
322 #}
323 #
324 # An example of a winmm output (Windows multimedia API).
325 #
326 #audio_output {
327 # type "winmm"
328 # name "My WinMM output"
329 ## device "Digital Audio (S/PDIF) (High Definition Audio Device)" # optional
330 # or
331 ## device "0" # optional
332 ## mixer_type "hardware" # optional
333 #}
334 #
335 # An example of an openal output.
336 #
337 #audio_output {
338 # type "openal"
339 # name "My OpenAL output"
340 ## device "Digital Audio (S/PDIF) (High Definition Audio Device)" # optional
341 #}
342 #
343 # An example of an sndio output.
344 #
345 #audio_output {
346 # type "sndio"
347 # name "sndio output"
348 # mixer_type "software"
349 #}
350 #
351 # An example of an OS X output:
352 #
353 #audio_output {
354 # type "osx"
355 # name "My OS X Device"
356 ## device "Built-in Output" # optional
357 ## channel_map "-1,-1,0,1" # optional
358 #}
359 #
360 ## Example "pipe" output:
361 #
362 #audio_output {
363 # type "pipe"
364 # name "my pipe"
365 # command "aplay -f cd 2>/dev/null"
366 ## Or if you're want to use AudioCompress
367 # command "AudioCompress -m | aplay -f cd 2>/dev/null"
368 ## Or to send raw PCM stream through PCM:
369 # command "nc example.org 8765"
370 # format "44100:16:2"
371 #}
372 #
373 ## An example of a null output (for no audio output):
374 #
375 #audio_output {
376 # type "null"
377 # name "My Null Output"
378 # mixer_type "none" # optional
379 #}
380 #
381 ###############################################################################
382
383
384 # Normalization automatic volume adjustments ##################################
385 #
386 # This setting specifies the type of ReplayGain to use. This setting can have
387 # the argument "off", "album", "track" or "auto". "auto" is a special mode that
388 # chooses between "track" and "album" depending on the current state of
389 # random playback. If random playback is enabled then "track" mode is used.
390 # See <http://www.replaygain.org> for more details about ReplayGain.
391 # This setting is off by default.
392 #
393 #replaygain "album"
394 #
395 # This setting sets the pre-amp used for files that have ReplayGain tags. By
396 # default this setting is disabled.
397 #
398 #replaygain_preamp "0"
399 #
400 # This setting sets the pre-amp used for files that do NOT have ReplayGain tags.
401 # By default this setting is disabled.
402 #
403 #replaygain_missing_preamp "0"
404 #
405 # This setting enables or disables ReplayGain limiting.
406 # MPD calculates actual amplification based on the ReplayGain tags
407 # and replaygain_preamp / replaygain_missing_preamp setting.
408 # If replaygain_limit is enabled MPD will never amplify audio signal
409 # above its original level. If replaygain_limit is disabled such amplification
410 # might occur. By default this setting is enabled.
411 #
412 #replaygain_limit "yes"
413 #
414 # This setting enables on-the-fly normalization volume adjustment. This will
415 # result in the volume of all playing audio to be adjusted so the output has
416 # equal "loudness". This setting is disabled by default.
417 #
418 #volume_normalization "no"
419 #
420 ###############################################################################
421
422 # Character Encoding ##########################################################
423 #
424 # If file or directory names do not display correctly for your locale then you
425 # may need to modify this setting.
426 #
427 #filesystem_charset "UTF-8"
428 #
429 ###############################################################################
430 #+end_src
431
432 ** ncmpcpp
433
434 *** config
435 :PROPERTIES:
436 :header-args+: :tangle ~/.ncmpcpp/config
437 :END:
438
439 #+begin_src conf :tangle no
440 ##############################################################
441 ## This is the example configuration file. Copy it to ##
442 ## $HOME/.ncmpcpp/config or $XDG_CONFIG_HOME/ncmpcpp/config ##
443 ## and set up your preferences. ##
444 ##############################################################
445 #
446 ##### directories ######
447 ##
448 ## Directory for storing ncmpcpp related files.
449 ## Changing it is useful if you want to store
450 ## everything somewhere else and provide command
451 ## line setting for alternative location to config
452 ## file which defines that while launching ncmpcpp.
453 ##
454 #
455 ncmpcpp_directory = ~/.ncmpcpp
456 #
457 ##
458 ## Directory for storing downloaded lyrics. It
459 ## defaults to ~/.lyrics since other MPD clients
460 ## (eg. ncmpc) also use that location.
461 ##
462 #
463 #lyrics_directory = ~/.lyrics
464 #
465 ##### connection settings #####
466 #
467 #mpd_host = localhost
468 #
469 #mpd_port = 6600
470 #
471 #mpd_connection_timeout = 5
472 #
473 ## Needed for tag editor and file operations to work.
474 ##
475 mpd_music_dir = ~/usr/music
476 #
477 #mpd_crossfade_time = 5
478 #
479 ##### music visualizer #####
480 ##
481 ## Note: In order to make music visualizer work you'll
482 ## need to use mpd fifo output, whose format parameter
483 ## has to be set to 44100:16:1 for mono visualization
484 ## or 44100:16:2 for stereo visualization. Example
485 ## configuration (it has to be put into mpd.conf):
486 ##
487 ## audio_output {
488 ## type "fifo"
489 ## name "Visualizer feed"
490 ## path "/tmp/mpd.fifo"
491 ## format "44100:16:2"
492 ## }
493 ##
494 #
495 visualizer_fifo_path = /tmp/mpd.fifo
496 #
497 ##
498 ## Note: Below parameter is needed for ncmpcpp
499 ## to determine which output provides data for
500 ## visualizer and thus allow syncing between
501 ## visualization and sound as currently there
502 ## are some problems with it.
503 ##
504 #
505 visualizer_output_name = my fifo
506 #
507 ##
508 ## If you set format to 44100:16:2, make it 'yes'.
509 ##
510 visualizer_in_stereo = yes
511 #
512 ##
513 ## Multiply received samples by given value. Very
514 ## useful for proper visualization of quiet music.
515 ##
516 #visualizer_sample_multiplier = 1
517 #
518 ##
519 ## Note: Below parameter defines how often ncmpcpp
520 ## has to "synchronize" visualizer and audio outputs.
521 ## 30 seconds is optimal value, but if you experience
522 ## synchronization problems, set it to lower value.
523 ## Keep in mind that sane values start with >=10.
524 ##
525 #
526 visualizer_sync_interval = 30
527 #
528 ##
529 ## Note: To enable spectrum frequency visualization
530 ## you need to compile ncmpcpp with fftw3 support.
531 ##
532 #
533 ## Available values: spectrum, wave, wave_filled, ellipse.
534 ##
535 visualizer_type = spectrum
536 #
537 #visualizer_look = ●▮
538 visualizer_look = "●•"
539 #
540 #visualizer_color = blue, cyan, green, yellow, magenta, red
541 #
542 ## Alternative subset of 256 colors for terminals that support it.
543 ##
544 #visualizer_color = 41, 83, 119, 155, 185, 215, 209, 203, 197, 161
545 #
546 ##### system encoding #####
547 ##
548 ## ncmpcpp should detect your charset encoding
549 ## but if it failed to do so, you can specify
550 ## charset encoding you are using here.
551 ##
552 ## Note: You can see whether your ncmpcpp build
553 ## supports charset detection by checking output
554 ## of `ncmpcpp --version`.
555 ##
556 ## Note: Since MPD uses UTF-8 by default, setting
557 ## this option makes sense only if your encoding
558 ## is different.
559 ##
560 #
561 #system_encoding = ""
562 #
563 ##### delays #####
564 #
565 ## Time of inactivity (in seconds) after playlist
566 ## highlighting will be disabled (0 = always on).
567 ##
568 #playlist_disable_highlight_delay = 5
569 #
570 ## Defines how long messages are supposed to be visible.
571 ##
572 #message_delay_time = 5
573 #
574 ##### song format #####
575 ##
576 ## For a song format you can use:
577 ##
578 ## %l - length
579 ## %f - filename
580 ## %D - directory
581 ## %a - artist
582 ## %A - album artist
583 ## %t - title
584 ## %b - album
585 ## %y - date
586 ## %n - track number (01/12 -> 01)
587 ## %N - full track info (01/12 -> 01/12)
588 ## %g - genre
589 ## %c - composer
590 ## %p - performer
591 ## %d - disc
592 ## %C - comment
593 ## %P - priority
594 ## $R - begin right alignment
595 ##
596 ## If you want to make sure that a part of the format is displayed
597 ## only when certain tags are present, you can archieve it by
598 ## grouping them with brackets, e.g. '{%a - %t}' will be evaluated
599 ## to 'ARTIST - TITLE' if both tags are present or '' otherwise.
600 ## It is also possible to define a list of alternatives by providing
601 ## several groups and separating them with '|', e.g. '{%t}|{%f}'
602 ## will be evaluated to 'TITLE' or 'FILENAME' if the former is not
603 ## present.
604 ##
605 ## Note: If you want to set limit on maximal length of a tag, just
606 ## put the appropriate number between % and character that defines
607 ## tag type, e.g. to make album take max. 20 terminal cells, use '%20b'.
608 ##
609 ## In addition, formats support markers used for text attributes.
610 ## They are followed by character '$'. After that you can put:
611 ##
612 ## - 0 - default window color (discards all other colors)
613 ## - 1 - black
614 ## - 2 - red
615 ## - 3 - green
616 ## - 4 - yellow
617 ## - 5 - blue
618 ## - 6 - magenta
619 ## - 7 - cyan
620 ## - 8 - white
621 ## - 9 - end of current color
622 ## - b - bold text
623 ## - u - underline text
624 ## - r - reverse colors
625 ## - a - use alternative character set
626 ##
627 ## If you don't want to use a non-color attribute anymore, just put it
628 ## again, but this time insert character '/' between '$' and attribute
629 ## character, e.g. {$b%t$/b}|{$r%f$/r} will display bolded title tag
630 ## or filename with reversed colors.
631 ##
632 ## If you want to use 256 colors and/or background colors in formats
633 ## (the naming scheme is described below in section about color
634 ## definitions), it can be done with the syntax $(COLOR), e.g. to set
635 ## the artist tag to one of the non-standard colors and make it have
636 ## yellow background, you need to write $(197_yellow)%a$(end). Note
637 ## that for standard colors this is interchangable with attributes
638 ## listed above.
639 ##
640 ## Note: colors can be nested.
641 ##
642 #
643 #song_list_format = {%a - }{%t}|{$8%f$9}$R{$3(%l)$9}
644 #
645 #song_status_format = {{%a{ "%b"{ (%y)}} - }{%t}}|{%f}
646 #
647 #song_library_format = {%n - }{%t}|{%f}
648 #
649 #
650 #alternative_header_first_line_format = $b$1$aqqu$/a$9 {%t}|{%f} $1$atqq$/a$9$/b
651 #
652 #alternative_header_second_line_format = {{$4$b%a$/b$9}{ - $7%b$9}{ ($4%y$9)}}|{%D}
653 #
654 #now_playing_prefix = $b
655 #
656 #now_playing_suffix = $/b
657 #
658 #browser_playlist_prefix = "$2playlist$9 "
659 #
660 #selected_item_prefix = $6
661 #
662 #selected_item_suffix = $9
663 #
664 #modified_item_prefix = $3> $9
665 #
666 ##
667 ## Note: attributes are not supported for the following variables.
668 ##
669 #song_window_title_format = {%a - }{%t}|{%f}
670 ##
671 ## Note: Below variables are used for sorting songs in browser.
672 ## The sort mode determines how songs are sorted, and can be used
673 ## in combination with a sort format to specify a custom sorting format.
674 ## Available values for browser_sort_mode are "name", "mtime", "format"
675 ## and "noop".
676 ##
677 #
678 #browser_sort_mode = name
679 #
680 #browser_sort_format = {%a - }{%t}|{%f} {(%l)}
681 #
682 ##### columns settings #####
683 ##
684 ## syntax of song columns list format is "column column etc."
685 ##
686 ## - syntax for each column is:
687 ##
688 ## (width of the column)[color of the column]{displayed tag}
689 ##
690 ## Note: Width is by default in %, if you want a column to
691 ## have fixed size, add 'f' after the value, e.g. (10)[white]{a}
692 ## will be the column that take 10% of screen (so the real width
693 ## will depend on actual screen size), whereas (10f)[white]{a}
694 ## will take 10 terminal cells, no matter how wide the screen is.
695 ##
696 ## - color is optional (if you want the default one,
697 ## leave the field empty).
698 ##
699 ## Note: You can give a column additional attributes by putting appropriate
700 ## character after displayed tag character. Available attributes are:
701 ##
702 ## - r - column will be right aligned
703 ## - E - if tag is empty, empty tag marker won't be displayed
704 ##
705 ## You can also:
706 ##
707 ## - give a column custom name by putting it after attributes,
708 ## separated with character ':', e.g. {lr:Length} gives you
709 ## right aligned column of lengths named "Length".
710 ##
711 ## - define sequence of tags, that have to be displayed in case
712 ## predecessor is empty in a way similar to the one in classic
713 ## song format, i.e. using '|' character, e.g. {a|c|p:Owner}
714 ## creates column named "Owner" that tries to display artist
715 ## tag and then composer and performer if previous ones are
716 ## not available.
717 ##
718 #
719 #song_columns_list_format = (20)[]{a} (6f)[green]{NE} (50)[white]{t|f:Title} (20)[cyan]{b} (7f)[magenta]{l}
720 #
721 ##### various settings #####
722 #
723 ##
724 ## Note: Custom command that will be executed each
725 ## time song changes. Useful for notifications etc.
726 ##
727 #execute_on_song_change = ""
728 #
729 #playlist_show_mpd_host = no
730 #
731 #playlist_show_remaining_time = no
732 #
733 #playlist_shorten_total_times = no
734 #
735 #playlist_separate_albums = no
736 #
737 ##
738 ## Note: Possible display modes: classic, columns.
739 ##
740 #playlist_display_mode = columns
741 #
742 #browser_display_mode = classic
743 #
744 #search_engine_display_mode = classic
745 #
746 #playlist_editor_display_mode = classic
747 #
748 #discard_colors_if_item_is_selected = yes
749 #
750 #incremental_seeking = yes
751 #
752 #seek_time = 1
753 #
754 #volume_change_step = 2
755 #
756 #autocenter_mode = no
757 #
758 #centered_cursor = no
759 #
760 ##
761 ## Note: You can specify third character which will
762 ## be used to build 'empty' part of progressbar.
763 ##
764 #progressbar_look = =>
765 progressbar_look = "─╼╶"
766 #progressbar_look = "─⊙╶"
767 #
768 #progressbar_boldness = yes
769 #
770 ## Available values: database, playlist.
771 ##
772 #default_place_to_search_in = database
773 #
774 ## Available values: classic, alternative.
775 ##
776 #user_interface = classic
777 #
778 #data_fetching_delay = yes
779 #
780 ## Available values: artist, album_artist, date, genre, composer, performer.
781 ##
782 #media_library_primary_tag = artist
783 #
784 ## Available values: wrapped, normal.
785 ##
786 #default_find_mode = wrapped
787 #
788 #default_tag_editor_pattern = %n - %t
789 #
790 #header_visibility = yes
791 #
792 #statusbar_visibility = yes
793 #
794 #titles_visibility = yes
795 #
796 #header_text_scrolling = yes
797 #
798 #cyclic_scrolling = no
799 #
800 #lines_scrolled = 2
801 #
802 #follow_now_playing_lyrics = no
803 #
804 #fetch_lyrics_for_current_song_in_background = no
805 #
806 #store_lyrics_in_song_dir = no
807 #
808 #generate_win32_compatible_filenames = yes
809 #
810 #allow_for_physical_item_deletion = no
811 #
812 ##
813 ## Note: If you set this variable, ncmpcpp will try to
814 ## get info from last.fm in language you set and if it
815 ## fails, it will fall back to english. Otherwise it will
816 ## use english the first time.
817 ##
818 ## Note: Language has to be expressed as an ISO 639 alpha-2 code.
819 ##
820 #lastfm_preferred_language = en
821 #
822 #show_hidden_files_in_local_browser = no
823 #
824 ##
825 ## How shall screen switcher work?
826 ##
827 ## - "previous" - switch between the current and previous screen.
828 ## - "screen1,...,screenN" - switch between given sequence of screens.
829 ##
830 ## Screens available for use: help, playlist, browser, search_engine,
831 ## media_library, playlist_editor, tag_editor, outputs, visualizer, clock.
832 ##
833 #screen_switcher_mode = playlist, browser
834 #
835 ##
836 ## Note: You can define startup screen
837 ## by choosing screen from the list above.
838 ##
839 #startup_screen = playlist
840 #
841 ##
842 ## Note: You can define startup slave screen
843 ## by choosing screen from the list above or
844 ## an empty value for no slave screen.
845 ##
846 #startup_slave_screen = ""
847 #
848 #startup_slave_screen_focus = no
849 #
850 ##
851 ## Default width of locked screen (in %).
852 ## Acceptable values are from 20 to 80.
853 ##
854 #
855 #locked_screen_width_part = 50
856 #
857 #ask_for_locked_screen_width_part = yes
858 #
859 #jump_to_now_playing_song_at_start = yes
860 #
861 #ask_before_clearing_playlists = yes
862 #
863 #clock_display_seconds = no
864 #
865 #display_volume_level = yes
866 #
867 #display_bitrate = no
868 #
869 #display_remaining_time = no
870 #
871 ## Available values: none, basic, extended, perl.
872 ##
873 #regular_expressions = perl
874 #
875 ##
876 ## Note: If below is enabled, ncmpcpp will ignore leading
877 ## "The" word while sorting items in browser, tags in
878 ## media library, etc.
879 ##
880 #ignore_leading_the = no
881 #
882 #block_search_constraints_change_if_items_found = yes
883 #
884 #mouse_support = yes
885 #
886 #mouse_list_scroll_whole_page = yes
887 #
888 #empty_tag_marker = <empty>
889 #
890 #tags_separator = " | "
891 #
892 #tag_editor_extended_numeration = no
893 #
894 #media_library_sort_by_mtime = no
895 #
896 #enable_window_title = yes
897 #
898 ##
899 ## Note: You can choose default search mode for search
900 ## engine. Available modes are:
901 ##
902 ## - 1 - use mpd built-in searching (no regexes, pattern matching)
903 ## - 2 - use ncmpcpp searching (pattern matching with support for regexes,
904 ## but if your mpd is on a remote machine, downloading big database
905 ## to process it can take a while
906 ## - 3 - match only exact values (this mode uses mpd function for searching
907 ## in database and local one for searching in current playlist)
908 ##
909 #
910 #search_engine_default_search_mode = 1
911 #
912 #external_editor = nano
913 #
914 ## Note: set to yes if external editor is a console application.
915 ##
916 #use_console_editor = yes
917 #
918 ##### colors definitions #####
919 ##
920 ## It is possible to set a background color by setting a color
921 ## value "<foreground>_<background>", e.g. red_black will set
922 ## foregound color to red and background color to black.
923 ##
924 ## In addition, for terminals that support 256 colors it
925 ## is possible to set one of them by using a number in range
926 ## [1, 256] instead of color name, e.g. numerical value
927 ## corresponding to red_black is 2_1. To find out if the
928 ## terminal supports 256 colors, run ncmpcpp and check out
929 ## the bottom of the help screen for list of available colors
930 ## and their numerical values.
931 ##
932 ## Note: due to technical limitations of ncurses, if 256 colors
933 ## are used, it is possible to either use only the colors with
934 ## default background color, or all pairs from 1_1 up to 254_127,
935 ## depending on the ncurses version used.
936 ##
937 #
938 #colors_enabled = yes
939 #
940 #empty_tag_color = cyan
941 #
942 #header_window_color = default
943 #
944 #volume_color = default
945 #
946 #state_line_color = default
947 #
948 #state_flags_color = default
949 #
950 #main_window_color = yellow
951 #
952 #color1 = white
953 #
954 #color2 = green
955 #
956 #main_window_highlight_color = yellow
957 #
958 #progressbar_color = black
959 #
960 #progressbar_elapsed_color = green
961 #
962 #statusbar_color = default
963 #
964 #alternative_ui_separator_color = black
965 #
966 #active_column_color = red
967 #
968 #window_border_color = green
969 #
970 #active_window_border = red
971 #
972 #+end_src
973
974 *** bindings
975 :PROPERTIES:
976 :header-args+: :tangle ~/.ncmpcpp/bindings
977 :END:
978
979 #+begin_src conf :tangle no
980 def_key "j"
981 scroll_down
982 def_key "k"
983 scroll_up
984
985 def_key "ctrl-u"
986 page_up
987 def_key "ctrl-d"
988 page_down
989
990 def_key "h"
991 previous_column
992 def_key "l"
993 next_column
994
995 def_key "."
996 show_lyrics
997
998 def_key "n"
999 next_found_item
1000 def_key "N"
1001 previous_found_item
1002
1003 def_key "J"
1004 move_sort_order_down
1005 def_key "K"
1006 move_sort_order_up
1007 #+end_src
1008
1009 ** pigeonhole
1010 *** amin.sieve
1011 :PROPERTIES:
1012 :header-args+: :tangle ~/mail/bndl.org/amin/sieve/amin.sieve :comments none
1013 :END:
1014
1015 #+begin_src conf
1016 require ["regex", "variables", "fileinto", "envelope",
1017 "mailbox", "imap4flags", "include"];
1018
1019 # webmasters
1020 if anyof (
1021 address :is "from" ["webmasters@gnu.org", "webmasters-comment@gnu.org"]) {
1022 fileinto :create "gnu.webmasters";
1023 stop;
1024 }
1025
1026 include :personal "lists";
1027 #+end_src
1028
1029 *** lists.sieve
1030 :PROPERTIES:
1031 :header-args+: :tangle ~/mail/bndl.org/amin/sieve/lists.sieve :comments none
1032 :END:
1033
1034 #+begin_src conf
1035 require ["regex", "variables", "fileinto", "envelope",
1036 "mailbox", "imap4flags", "include"];
1037
1038 # mailing lists
1039 if anyof (
1040 header :contains "list-id"
1041 [ "<emacs-devel.gnu.org>"
1042 , "<emacs-orgmode.gnu.org>"
1043 , "<emacsconf-discuss.gnu.org>"
1044 , "<fencepost-users.gnu.org>"
1045 , "<guix-devel.gnu.org>"
1046 , "<guile-devel.gnu.org>"
1047 , "<help-gnu-emacs.gnu.org>"
1048 , "<info-gnu-emacs.gnu.org>"
1049 , "<info-guix.gnu.org>"
1050 , "<www-commits.gnu.org>"
1051 , "<www-discuss.gnu.org>"
1052 , "<deepspec.lists.cs.princeton.edu>"
1053 , "<haskell-cafe.haskell.org>"
1054 , "<haskell-art.we.lurk.org>"
1055 , "<notmuch.notmuchmail.org>"
1056 ] ) {
1057 if header :regex "list-id" "<([a-z_0-9-]+)[.@]" {
1058 set :lower "listname" "${1}";
1059 fileinto :create "gnu.${listname}";
1060 stop;
1061 }
1062 }
1063
1064 # sr.ht lists, with dots ('.') omitted
1065 if anyof (
1066 header :contains "list-id"
1067 [ "<~bandali/public-inbox@lists.sr.ht>"
1068 , "<~sircmpwn/sr.ht-admins@lists.sr.ht>"
1069 , "<~sircmpwn/sr.ht-announce@lists.sr.ht>"
1070 , "<~sircmpwn/sr.ht-dev@lists.sr.ht>"
1071 , "<~sircmpwn/sr.ht-discuss@lists.sr.ht>"
1072 ] ) {
1073 if header :regex "list-id" "(~[a-z_0-9-]+)/([^.]*)\\.?([^.]*)\\.?([^.]*)\\.?([^.]*)\\.?([^.]*)\\.?([^.]*)@" {
1074 set :lower "username" "${1}";
1075 set :lower "listname" "${2}${3}${4}${5}${6}${7}";
1076 fileinto :create "gnu.${username}.${listname}";
1077 stop;
1078 }
1079 }
1080 #+end_src
1081
1082 ** redshift
1083 :PROPERTIES:
1084 :header-args+: :tangle ~/.config/redshift.conf :comments none
1085 :END:
1086
1087 #+begin_src conf
1088 ; Global settings for redshift
1089 [redshift]
1090 ; Set the day and night screen temperatures (Neutral is 6500K)
1091 ;temp-day=5700
1092 ;temp-night=3500
1093
1094 ;temp-day=6500
1095 temp-day=6200
1096 ;temp-night=4800
1097 ;temp-night=5000
1098 ;temp-night=4500
1099 temp-night=4000
1100
1101 ; Enable/Disable a smooth transition between day and night
1102 ; 0 will cause a direct change from day to night screen temperature.
1103 ; 1 will gradually increase or decrease the screen temperature.
1104 transition=1
1105
1106 ; Set the screen brightness. Default is 1.0.
1107 ;brightness=0.9
1108 ; It is also possible to use different settings for day and night
1109 ; since version 1.8.
1110 ;brightness-day=0.7
1111 ;brightness-night=0.4
1112 ; Set the screen gamma (for all colors, or each color channel
1113 ; individually)
1114 ;gamma=0.8
1115 ;gamma=1.0
1116 ;gamma=0.8:0.7:0.8
1117 ; This can also be set individually for day and night since
1118 ; version 1.10.
1119 ;gamma-day=0.8:0.7:0.8
1120 ;gamma-night=0.6
1121
1122 ; Set the location-provider: 'geoclue2' or 'manual'
1123 ; type 'redshift -l list' to see possible values.
1124 ; The location provider settings are in a different section.
1125 ;location-provider=manual
1126 location-provider=geoclue2
1127
1128 ; Set the adjustment-method: 'randr', 'vidmode'
1129 ; type 'redshift -m list' to see all possible values.
1130 ; 'randr' is the preferred method, 'vidmode' is an older API.
1131 ; but works in some cases when 'randr' does not.
1132 ; The adjustment method settings are in a different section.
1133 adjustment-method=randr
1134
1135 ; Configuration of the location-provider:
1136 ; type 'redshift -l PROVIDER:help' to see the settings.
1137 ; ex: 'redshift -l manual:help'
1138 ; Keep in mind that longitudes west of Greenwich (e.g. the Americas)
1139 ; are negative numbers.
1140 ;[manual]
1141 ;lat=48.1
1142 ;lon=11.6
1143
1144 ; Configuration of the adjustment-method
1145 ; type 'redshift -m METHOD:help' to see the settings.
1146 ; ex: 'redshift -m randr:help'
1147 ; In this example, randr is configured to adjust screen 1.
1148 ; Note that the numbering starts from 0, so this is actually the
1149 ; second screen. If this option is not specified, Redshift will try
1150 ; to adjust _all_ screens.
1151 ;[randr]
1152 ;screen=1
1153 #+end_src
1154
1155 ** systemd
1156
1157 Keep boot messages on tty1 (see [[https://wiki.archlinux.org/index.php/getty#Have_boot_messages_stay_on_tty1][here]])
1158
1159 #+begin_src conf :tangle /sudo::/etc/systemd/system/getty@tty1.service.d/noclear.conf
1160 [Service]
1161 TTYVTDisallocate=no
1162 #+end_src
1163
1164 ** TLP
1165
1166 *** langa
1167
1168 #+begin_src conf :tangle (when (and (eq system-type 'gnu/linux) (string= (system-name) "langa")) "/sudo::/etc/default/tlp")
1169 # ------------------------------------------------------------------------------
1170 # tlp - Parameters for power saving
1171 # See full explanation: https://linrunner.de/en/tlp/docs/tlp-configuration.html
1172
1173 # Notes:
1174 # - Some parameters are disabled, remove the leading '#' to enable # them;
1175 # shown values are suggestions not defaults
1176 # - Default *: intrinsic default that is effective when the parameter is missing
1177 # or disabled by a leading '#'; use PARAM="" to disable intrinsic defaults for
1178 # parameters with text string values
1179 # - Default <none>: do nothing or use kernel/hardware defaults
1180
1181 # Set to 0 to disable, 1 to enable TLP.
1182 # Default: 0
1183 TLP_ENABLE=1
1184
1185 # Operation mode when no power supply can be detected: AC, BAT.
1186 # Concerns some desktop and embedded hardware only.
1187 # Default: <none>
1188 TLP_DEFAULT_MODE=AC
1189
1190 # Operation mode select: 0=depend on power source, 1=always use TLP_DEFAULT_MODE
1191 # Hint: use in conjunction with TLP_DEFAULT_MODE=BAT for BAT settings on AC.
1192 # Default: 0
1193 TLP_PERSISTENT_DEFAULT=0
1194
1195 # Seconds laptop mode has to wait after the disk goes idle before doing a sync.
1196 # Non-zero value enables, zero disables laptop mode.
1197 # Default: 0 (AC), 2 (BAT)
1198 DISK_IDLE_SECS_ON_AC=0
1199 DISK_IDLE_SECS_ON_BAT=2
1200
1201 # Dirty page values (timeouts in secs).
1202 # Default: 15 (AC + BAT)
1203 MAX_LOST_WORK_SECS_ON_AC=15
1204 MAX_LOST_WORK_SECS_ON_BAT=60
1205
1206 # Note: CPU parameters below are disabled by default, remove the leading #
1207 # to enable them, otherwise kernel defaults will be used.
1208
1209 # Select a CPU frequency scaling governor.
1210 # Intel Core i processor with intel_pstate driver:
1211 # powersave(*), performance.
1212 # Older hardware with acpi-cpufreq driver:
1213 # ondemand(*), powersave, performance, conservative, schedutil.
1214 # (*) is recommended.
1215 # Use tlp-stat -p to show the active driver and available governors.
1216 # Important:
1217 # powersave for intel_pstate and ondemand for acpi-cpufreq are power
1218 # efficient for *almost all* workloads and therefore kernel and most
1219 # distributions have chosen them as defaults. If you still want to change,
1220 # you should know what you're doing! You *must* disable your distribution's
1221 # governor settings or conflicts will occur.
1222 # Default: <none>
1223 #CPU_SCALING_GOVERNOR_ON_AC=powersave
1224 #CPU_SCALING_GOVERNOR_ON_BAT=powersave
1225
1226 # Set the min/max frequency available for the scaling governor.
1227 # Possible values depend on your CPU. For available frequencies see
1228 # the output of tlp-stat -p.
1229 # Default: <none>
1230 #CPU_SCALING_MIN_FREQ_ON_AC=0
1231 #CPU_SCALING_MAX_FREQ_ON_AC=0
1232 #CPU_SCALING_MIN_FREQ_ON_BAT=0
1233 #CPU_SCALING_MAX_FREQ_ON_BAT=0
1234
1235 # Set energy performance hints (HWP) for Intel P-state governor:
1236 # performance, balance_performance, default, balance_power, power
1237 # Values are given in order of increasing power saving.
1238 # Note: Intel Skylake or newer CPU and Kernel >= 4.10 required.
1239 # Default: <none>
1240 CPU_HWP_ON_AC=balance_performance
1241 CPU_HWP_ON_BAT=balance_power
1242
1243 # Set Intel P-state performance: 0..100 (%).
1244 # Limit the max/min P-state to control the power dissipation of the CPU.
1245 # Values are stated as a percentage of the available performance.
1246 # Requires an Intel Core i processor with intel_pstate driver.
1247 # Default: <none>
1248 #CPU_MIN_PERF_ON_AC=0
1249 #CPU_MAX_PERF_ON_AC=100
1250 #CPU_MIN_PERF_ON_BAT=0
1251 #CPU_MAX_PERF_ON_BAT=30
1252
1253 # Set the CPU "turbo boost" feature: 0=disable, 1=allow
1254 # Requires an Intel Core i processor.
1255 # Important:
1256 # - This may conflict with your distribution's governor settings
1257 # - A value of 1 does *not* activate boosting, it just allows it
1258 # Default: <none>
1259 #CPU_BOOST_ON_AC=1
1260 #CPU_BOOST_ON_BAT=0
1261
1262 # Minimize number of used CPU cores/hyper-threads under light load conditions:
1263 # 0=disable, 1=enable.
1264 # Default: <none>
1265 SCHED_POWERSAVE_ON_AC=0
1266 SCHED_POWERSAVE_ON_BAT=1
1267
1268 # Kernel NMI Watchdog:
1269 # 0=disable (default, saves power), 1=enable (for kernel debugging only).
1270 # Default: <none>
1271 NMI_WATCHDOG=0
1272
1273 # Change CPU voltages aka "undervolting" - Kernel with PHC patch required.
1274 # Frequency voltage pairs are written to:
1275 # /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
1276 # CAUTION: only use this, if you thoroughly understand what you are doing!
1277 # Default: <none>.
1278 #PHC_CONTROLS="F:V F:V F:V F:V"
1279
1280 # Set CPU performance versus energy savings policy:
1281 # performance, balance-performance, default, balance-power, power.
1282 # Values are given in order of increasing power saving.
1283 # Requires kernel module msr and x86_energy_perf_policy from linux-tools.
1284 # Default: <none>
1285 ENERGY_PERF_POLICY_ON_AC=performance
1286 ENERGY_PERF_POLICY_ON_BAT=balance-power
1287
1288 # Disk devices; separate multiple devices with spaces.
1289 # Devices can be specified by disk ID also (lookup with: tlp diskid).
1290 # Note: DISK parameters below are effective only when this option is configured.
1291 # Default: "nvme0n1 sda"
1292 DISK_DEVICES="sda sdb"
1293
1294 # Disk advanced power management level: 1..254, 255 (max saving, min, off).
1295 # Levels 1..127 may spin down the disk; 255 allowable on most drives.
1296 # Separate values for multiple disks with spaces. Use the special value 'keep'
1297 # to keep the hardware default for the particular disk.
1298 # Default: <none>
1299 DISK_APM_LEVEL_ON_AC="254 254"
1300 DISK_APM_LEVEL_ON_BAT="128 128"
1301
1302 # Hard disk spin down timeout:
1303 # 0: spin down disabled
1304 # 1..240: timeouts from 5s to 20min (in units of 5s)
1305 # 241..251: timeouts from 30min to 5.5 hours (in units of 30min)
1306 # See 'man hdparm' for details.
1307 # Separate values for multiple disks with spaces. Use the special value 'keep'
1308 # to keep the hardware default for the particular disk.
1309 # Default: <none>
1310 #DISK_SPINDOWN_TIMEOUT_ON_AC="0 0"
1311 #DISK_SPINDOWN_TIMEOUT_ON_BAT="0 0"
1312
1313 # Select I/O scheduler for the disk devices.
1314 # Multi queue (blk-mq) schedulers:
1315 # mq-deadline(*), none, kyber, bfq
1316 # Single queue schedulers:
1317 # deadline(*), cfq, bfq, noop
1318 # (*) recommended.
1319 # Separate values for multiple disks with spaces. Use the special value 'keep'
1320 # to keep the kernel default scheduler for the particular disk.
1321 # Notes:
1322 # - Multi queue (blk-mq) may need kernel boot option 'scsi_mod.use_blk_mq=1'
1323 # and 'modprobe mq-deadline-iosched|kyber|bfq' on kernels < 5.0
1324 # - Single queue schedulers are legacy now and were removed together with
1325 # the old block layer in kernel 5.0
1326 # Default: keep
1327 #DISK_IOSCHED="mq-deadline mq-deadline"
1328
1329 # AHCI link power management (ALPM) for disk devices:
1330 # min_power, med_power_with_dipm(*), medium_power, max_performance.
1331 # (*) Kernel >= 4.15 required, then recommended.
1332 # Multiple values separated with spaces are tried sequentially until success.
1333 # Default: <none>
1334 SATA_LINKPWR_ON_AC="med_power_with_dipm max_performance"
1335 SATA_LINKPWR_ON_BAT="med_power_with_dipm min_power"
1336
1337 # Exclude host devices from AHCI link power management.
1338 # Separate multiple hosts with spaces.
1339 # Default: <none>
1340 #SATA_LINKPWR_BLACKLIST="host1"
1341
1342 # Runtime Power Management for AHCI host and disks devices:
1343 # on=disable, auto=enable.
1344 # EXPERIMENTAL ** WARNING: auto may cause system lockups/data loss.
1345 # Default: <none>
1346 #AHCI_RUNTIME_PM_ON_AC=on
1347 #AHCI_RUNTIME_PM_ON_BAT=on
1348
1349 # Seconds of inactivity before disk is suspended.
1350 # Note: effective only when AHCI_RUNTIME_PM_ON_AC/BAT is activated.
1351 # Default: 15
1352 AHCI_RUNTIME_PM_TIMEOUT=15
1353
1354 # PCI Express Active State Power Management (PCIe ASPM):
1355 # default(*), performance, powersave.
1356 # (*) keeps BIOS ASPM defaults (recommended)
1357 # Default: <none>
1358 #PCIE_ASPM_ON_AC=default
1359 #PCIE_ASPM_ON_BAT=default
1360
1361 # Set the min/max/turbo frequency for the Intel GPU.
1362 # Possible values depend on your hardware. For available frequencies see
1363 # the output of tlp-stat -g.
1364 # Default: <none>
1365 #INTEL_GPU_MIN_FREQ_ON_AC=0
1366 #INTEL_GPU_MIN_FREQ_ON_BAT=0
1367 #INTEL_GPU_MAX_FREQ_ON_AC=0
1368 #INTEL_GPU_MAX_FREQ_ON_BAT=0
1369 #INTEL_GPU_BOOST_FREQ_ON_AC=0
1370 #INTEL_GPU_BOOST_FREQ_ON_BAT=0
1371
1372 # Radeon graphics clock speed (profile method): low, mid, high, auto, default;
1373 # auto = mid on BAT, high on AC.
1374 # Default: default
1375 RADEON_POWER_PROFILE_ON_AC=default
1376 RADEON_POWER_PROFILE_ON_BAT=default
1377
1378 # Radeon dynamic power management method (DPM): battery, performance.
1379 # Default: <none>
1380 RADEON_DPM_STATE_ON_AC=performance
1381 RADEON_DPM_STATE_ON_BAT=battery
1382
1383 # Radeon DPM performance level: auto, low, high; auto is recommended.
1384 # Note: effective only when RADEON_DPM_STATE_ON_AC/BAT is activated.
1385 # Default: auto
1386 RADEON_DPM_PERF_LEVEL_ON_AC=auto
1387 RADEON_DPM_PERF_LEVEL_ON_BAT=auto
1388
1389 # WiFi power saving mode: on=enable, off=disable; not supported by all adapters.
1390 # Default: <none>
1391 WIFI_PWR_ON_AC=off
1392 WIFI_PWR_ON_BAT=on
1393
1394 # Disable wake on LAN: Y/N.
1395 # Default: N
1396 WOL_DISABLE=Y
1397
1398 # Enable audio power saving for Intel HDA, AC97 devices (timeout in secs).
1399 # A value of 0 disables, >=1 enables power saving (recommended: 1).
1400 # Default: <none>
1401 SOUND_POWER_SAVE_ON_AC=0
1402 SOUND_POWER_SAVE_ON_BAT=0
1403
1404 # Disable controller too (HDA only): Y/N.
1405 # Note: effective only when SOUND_POWER_SAVE_ON_AC/BAT is activated.
1406 # Default: Y
1407 SOUND_POWER_SAVE_CONTROLLER=N
1408
1409 # Power off optical drive in UltraBay/MediaBay: 0=disable, 1=enable.
1410 # Drive can be powered on again by releasing (and reinserting) the eject lever
1411 # or by pressing the disc eject button on newer models.
1412 # Note: an UltraBay/MediaBay hard disk is never powered off.
1413 # Default: 0
1414 BAY_POWEROFF_ON_AC=0
1415 BAY_POWEROFF_ON_BAT=0
1416 # Optical drive device to power off
1417 # Default: sr0
1418 BAY_DEVICE="sr0"
1419
1420 # Runtime Power Management for PCI(e) bus devices: on=disable, auto=enable.
1421 # Default: <none>
1422 RUNTIME_PM_ON_AC=on
1423 RUNTIME_PM_ON_BAT=auto
1424
1425 # Exclude PCI(e) device adresses the following list from Runtime PM
1426 # (separate with spaces). Use lspci to get the adresses (1st column).
1427 # Default: <none>
1428 #RUNTIME_PM_BLACKLIST="bb:dd.f 11:22.3 44:55.6"
1429
1430 # Exclude PCI(e) devices assigned to the listed drivers from Runtime PM.
1431 # Default when unconfigured is "amdgpu nouveau nvidia radeon" which
1432 # prevents accidential power-on of dGPU in hybrid graphics setups.
1433 # Separate multiple drivers with spaces.
1434 # Default: "amdgpu mei_me nouveau nvidia pcieport radeon", use "" to disable
1435 # completely.
1436 #RUNTIME_PM_DRIVER_BLACKLIST="amdgpu mei_me nouveau nvidia pcieport radeon"
1437
1438 # Set to 0 to disable, 1 to enable USB autosuspend feature.
1439 # Default: 0
1440 USB_AUTOSUSPEND=1
1441
1442 # Exclude listed devices from USB autosuspend (separate with spaces).
1443 # Use lsusb to get the ids.
1444 # Note: input devices (usbhid) are excluded automatically
1445 # Default: <none>
1446 #USB_BLACKLIST="1111:2222 3333:4444"
1447
1448 # Bluetooth devices are excluded from USB autosuspend:
1449 # 0=do not exclude, 1=exclude.
1450 # Default: 0
1451 USB_BLACKLIST_BTUSB=0
1452
1453 # Phone devices are excluded from USB autosuspend:
1454 # 0=do not exclude, 1=exclude (enable charging).
1455 # Default: 0
1456 USB_BLACKLIST_PHONE=0
1457
1458 # Printers are excluded from USB autosuspend:
1459 # 0=do not exclude, 1=exclude.
1460 # Default: 1
1461 USB_BLACKLIST_PRINTER=1
1462
1463 # WWAN devices are excluded from USB autosuspend:
1464 # 0=do not exclude, 1=exclude.
1465 # Default: 0
1466 USB_BLACKLIST_WWAN=0
1467
1468 # Include listed devices into USB autosuspend even if already excluded
1469 # by the blacklists above (separate with spaces). Use lsusb to get the ids.
1470 # Default: <none>
1471 #USB_WHITELIST="1111:2222 3333:4444"
1472
1473 # Set to 1 to disable autosuspend before shutdown, 0 to do nothing
1474 # (workaround for USB devices that cause shutdown problems).
1475 # Default: 0
1476 #USB_AUTOSUSPEND_DISABLE_ON_SHUTDOWN=1
1477
1478 # Restore radio device state (Bluetooth, WiFi, WWAN) from previous shutdown
1479 # on system startup: 0=disable, 1=enable.
1480 # Note: the parameters DEVICES_TO_DISABLE/ENABLE_ON_STARTUP/SHUTDOWN below
1481 # are ignored when this is enabled.
1482 # Default: 0
1483 #RESTORE_DEVICE_STATE_ON_STARTUP=0
1484 RESTORE_DEVICE_STATE_ON_STARTUP=1
1485
1486 # Radio devices to disable on startup: bluetooth, wifi, wwan.
1487 # Separate multiple devices with spaces.
1488 # Default: <none>
1489 #DEVICES_TO_DISABLE_ON_STARTUP="bluetooth wifi wwan"
1490
1491 # Radio devices to enable on startup: bluetooth, wifi, wwan.
1492 # Separate multiple devices with spaces.
1493 # Default: <none>
1494 #DEVICES_TO_ENABLE_ON_STARTUP="wifi"
1495
1496 # Radio devices to disable on shutdown: bluetooth, wifi, wwan.
1497 # (workaround for devices that are blocking shutdown).
1498 # Default: <none>
1499 #DEVICES_TO_DISABLE_ON_SHUTDOWN="bluetooth wifi wwan"
1500
1501 # Radio devices to enable on shutdown: bluetooth, wifi, wwan.
1502 # (to prevent other operating systems from missing radios).
1503 # Default: <none>
1504 #DEVICES_TO_ENABLE_ON_SHUTDOWN="wwan"
1505
1506 # Radio devices to enable on AC: bluetooth, wifi, wwan.
1507 # Default: <none>
1508 #DEVICES_TO_ENABLE_ON_AC="bluetooth wifi wwan"
1509
1510 # Radio devices to disable on battery: bluetooth, wifi, wwan.
1511 # Default: <none>
1512 #DEVICES_TO_DISABLE_ON_BAT="bluetooth wifi wwan"
1513 DEVICES_TO_DISABLE_ON_BAT="bluetooth"
1514
1515 # Radio devices to disable on battery when not in use (not connected):
1516 # bluetooth, wifi, wwan.
1517 # Default: <none>
1518 #DEVICES_TO_DISABLE_ON_BAT_NOT_IN_USE="bluetooth wifi wwan"
1519
1520 # Battery charge thresholds (ThinkPad only, tp-smapi or acpi-call kernel module
1521 # required). Charging starts when the remaining capacity falls below the
1522 # START_CHARGE_THRESH value and stops when exceeding the STOP_CHARGE_THRESH value.
1523 # Main / Internal battery (values in %)
1524 # Default: <none>
1525 #START_CHARGE_THRESH_BAT0=75
1526 #STOP_CHARGE_THRESH_BAT0=80
1527 # Ultrabay / Slice / Replaceable battery (values in %)
1528 # Default: <none>
1529 #START_CHARGE_THRESH_BAT1=75
1530 #STOP_CHARGE_THRESH_BAT1=80
1531
1532 # Restore charge thresholds when AC is unplugged: 0=disable, 1=enable.
1533 # Default: 0
1534 #RESTORE_THRESHOLDS_ON_BAT=1
1535
1536 # Battery feature drivers: 0=disable, 1=enable
1537 # Default: 1 (all)
1538 NATACPI_ENABLE=1
1539 TPACPI_ENABLE=1
1540 TPSMAPI_ENABLE=1
1541
1542 # ------------------------------------------------------------------------------
1543 # tlp-rdw - Parameters for the radio device wizard
1544 # Possible devices: bluetooth, wifi, wwan.
1545
1546 # Notes:
1547 # - Parameters are disabled by default, remove the leading # to enable them
1548 # - Separate multiple radio devices with spaces
1549
1550 # Default: <none> (for all parameters below)
1551
1552 # Radio devices to disable on connect.
1553 #DEVICES_TO_DISABLE_ON_LAN_CONNECT="wifi wwan"
1554 #DEVICES_TO_DISABLE_ON_WIFI_CONNECT="wwan"
1555 #DEVICES_TO_DISABLE_ON_WWAN_CONNECT="wifi"
1556
1557 # Radio devices to enable on disconnect.
1558 #DEVICES_TO_ENABLE_ON_LAN_DISCONNECT="wifi wwan"
1559 #DEVICES_TO_ENABLE_ON_WIFI_DISCONNECT=""
1560 #DEVICES_TO_ENABLE_ON_WWAN_DISCONNECT=""
1561
1562 # Radio devices to enable/disable when docked.
1563 #DEVICES_TO_ENABLE_ON_DOCK=""
1564 #DEVICES_TO_DISABLE_ON_DOCK=""
1565
1566 # Radio devices to enable/disable when undocked.
1567 #DEVICES_TO_ENABLE_ON_UNDOCK="wifi"
1568 #DEVICES_TO_DISABLE_ON_UNDOCK=""
1569 #+end_src
1570
1571 *** shemshak
1572
1573 #+begin_src conf :tangle (when (and (eq system-type 'gnu/linux) (string= (system-name) "shemshak")) "/sudo::/etc/default/tlp")
1574 # ------------------------------------------------------------------------------
1575 # tlp - Parameters for power saving
1576 # See full explanation: http://linrunner.de/en/tlp/docs/tlp-configuration.html
1577
1578 # Hint: some features are disabled by default, remove the leading # to enable
1579 # them.
1580
1581 # Set to 0 to disable, 1 to enable TLP.
1582 TLP_ENABLE=1
1583
1584 # Operation mode when no power supply can be detected: AC, BAT.
1585 # Concerns some desktop and embedded hardware only.
1586 TLP_DEFAULT_MODE=AC
1587
1588 # Operation mode select: 0=depend on power source, 1=always use TLP_DEFAULT_MODE
1589 # Hint: use in conjunction with TLP_DEFAULT_MODE=BAT for BAT settings on AC.
1590 TLP_PERSISTENT_DEFAULT=0
1591
1592 # Seconds laptop mode has to wait after the disk goes idle before doing a sync.
1593 # Non-zero value enables, zero disables laptop mode.
1594 DISK_IDLE_SECS_ON_AC=0
1595 DISK_IDLE_SECS_ON_BAT=2
1596
1597 # Dirty page values (timeouts in secs).
1598 MAX_LOST_WORK_SECS_ON_AC=15
1599 MAX_LOST_WORK_SECS_ON_BAT=60
1600
1601 # Hint: CPU parameters below are disabled by default, remove the leading #
1602 # to enable them, otherwise kernel default values are used.
1603
1604 # Select a CPU frequency scaling governor.
1605 # Intel Core i processor with intel_pstate driver:
1606 # powersave(*), performance.
1607 # Older hardware with acpi-cpufreq driver:
1608 # ondemand(*), powersave, performance, conservative, schedutil.
1609 # (*) is recommended.
1610 # Hint: use tlp-stat -p to show the active driver and available governors.
1611 # Important:
1612 # powersave for intel_pstate and ondemand for acpi-cpufreq are power
1613 # efficient for *almost all* workloads and therefore kernel and most
1614 # distributions have chosen them as defaults. If you still want to change,
1615 # you should know what you're doing! You *must* disable your distribution's
1616 # governor settings or conflicts will occur.
1617 #CPU_SCALING_GOVERNOR_ON_AC=powersave
1618 #CPU_SCALING_GOVERNOR_ON_BAT=powersave
1619
1620 # Set the min/max frequency available for the scaling governor.
1621 # Possible values strongly depend on your CPU. For available frequencies see
1622 # the output of tlp-stat -p.
1623 #CPU_SCALING_MIN_FREQ_ON_AC=0
1624 #CPU_SCALING_MAX_FREQ_ON_AC=0
1625 #CPU_SCALING_MIN_FREQ_ON_BAT=0
1626 #CPU_SCALING_MAX_FREQ_ON_BAT=0
1627
1628 # Set energy performance hints (HWP) for Intel P-state governor:
1629 # performance, balance_performance, default, balance_power, power
1630 # Values are given in order of increasing power saving.
1631 # Note: Intel Skylake or newer CPU and Kernel >= 4.10 required.
1632 CPU_HWP_ON_AC=balance_performance
1633 CPU_HWP_ON_BAT=balance_power
1634
1635 # Set Intel P-state performance: 0..100 (%).
1636 # Limit the max/min P-state to control the power dissipation of the CPU.
1637 # Values are stated as a percentage of the available performance.
1638 # Requires an Intel Core i processor with intel_pstate driver.
1639 #CPU_MIN_PERF_ON_AC=0
1640 #CPU_MAX_PERF_ON_AC=100
1641 #CPU_MIN_PERF_ON_BAT=0
1642 #CPU_MAX_PERF_ON_BAT=30
1643
1644 # Set the CPU "turbo boost" feature: 0=disable, 1=allow
1645 # Requires an Intel Core i processor.
1646 # Important:
1647 # - This may conflict with your distribution's governor settings
1648 # - A value of 1 does *not* activate boosting, it just allows it
1649 #CPU_BOOST_ON_AC=1
1650 #CPU_BOOST_ON_BAT=0
1651
1652 # Minimize number of used CPU cores/hyper-threads under light load conditions:
1653 # 0=disable, 1=enable.
1654 SCHED_POWERSAVE_ON_AC=0
1655 SCHED_POWERSAVE_ON_BAT=1
1656
1657 # Kernel NMI Watchdog:
1658 # 0=disable (default, saves power), 1=enable (for kernel debugging only).
1659 NMI_WATCHDOG=0
1660
1661 # Change CPU voltages aka "undervolting" - Kernel with PHC patch required.
1662 # Frequency voltage pairs are written to:
1663 # /sys/devices/system/cpu/cpu0/cpufreq/phc_controls
1664 # CAUTION: only use this, if you thoroughly understand what you are doing!
1665 #PHC_CONTROLS="F:V F:V F:V F:V"
1666
1667 # Set CPU performance versus energy savings policy:
1668 # performance, balance-performance, default, balance-power, power.
1669 # Values are given in order of increasing power saving.
1670 # Requires kernel module msr and x86_energy_perf_policy from linux-tools.
1671 ENERGY_PERF_POLICY_ON_AC=performance
1672 ENERGY_PERF_POLICY_ON_BAT=balance-power
1673
1674 # Disk devices; separate multiple devices with spaces (default: sda).
1675 # Devices can be specified by disk ID also (lookup with: tlp diskid).
1676 DISK_DEVICES="sda sdb"
1677
1678 # Disk advanced power management level: 1..254, 255 (max saving, min, off).
1679 # Levels 1..127 may spin down the disk; 255 allowable on most drives.
1680 # Separate values for multiple disks with spaces. Use the special value 'keep'
1681 # to keep the hardware default for the particular disk.
1682 DISK_APM_LEVEL_ON_AC="254 254"
1683 DISK_APM_LEVEL_ON_BAT="128 128"
1684
1685 # Hard disk spin down timeout:
1686 # 0: spin down disabled
1687 # 1..240: timeouts from 5s to 20min (in units of 5s)
1688 # 241..251: timeouts from 30min to 5.5 hours (in units of 30min)
1689 # See 'man hdparm' for details.
1690 # Separate values for multiple disks with spaces. Use the special value 'keep'
1691 # to keep the hardware default for the particular disk.
1692 #DISK_SPINDOWN_TIMEOUT_ON_AC="0 0"
1693 #DISK_SPINDOWN_TIMEOUT_ON_BAT="0 0"
1694
1695 # Select IO scheduler for the disk devices: cfq, deadline, noop (Default: cfq).
1696 # Separate values for multiple disks with spaces. Use the special value 'keep'
1697 # to keep the kernel default scheduler for the particular disk.
1698 #DISK_IOSCHED="cfq cfq"
1699
1700 # AHCI link power management (ALPM) for disk devices:
1701 # min_power, med_power_with_dipm(*), medium_power, max_performance.
1702 # (*) Kernel >= 4.15 required, then recommended.
1703 # Multiple values separated with spaces are tried sequentially until success.
1704 SATA_LINKPWR_ON_AC="med_power_with_dipm max_performance"
1705 SATA_LINKPWR_ON_BAT="med_power_with_dipm min_power"
1706
1707 # Exclude host devices from AHCI link power management.
1708 # Separate multiple hosts with spaces.
1709 #SATA_LINKPWR_BLACKLIST="host1"
1710
1711 # Runtime Power Management for AHCI host and disks devices:
1712 # on=disable, auto=enable.
1713 # EXPERIMENTAL ** WARNING: auto will most likely cause system lockups/data loss.
1714 #AHCI_RUNTIME_PM_ON_AC=on
1715 #AHCI_RUNTIME_PM_ON_BAT=on
1716
1717 # Seconds of inactivity before disk is suspended.
1718 AHCI_RUNTIME_PM_TIMEOUT=15
1719
1720 # PCI Express Active State Power Management (PCIe ASPM):
1721 # default, performance, powersave.
1722 PCIE_ASPM_ON_AC=performance
1723 PCIE_ASPM_ON_BAT=powersave
1724
1725 # Radeon graphics clock speed (profile method): low, mid, high, auto, default;
1726 # auto = mid on BAT, high on AC; default = use hardware defaults.
1727 RADEON_POWER_PROFILE_ON_AC=high
1728 RADEON_POWER_PROFILE_ON_BAT=low
1729
1730 # Radeon dynamic power management method (DPM): battery, performance.
1731 RADEON_DPM_STATE_ON_AC=performance
1732 RADEON_DPM_STATE_ON_BAT=battery
1733
1734 # Radeon DPM performance level: auto, low, high; auto is recommended.
1735 RADEON_DPM_PERF_LEVEL_ON_AC=auto
1736 RADEON_DPM_PERF_LEVEL_ON_BAT=auto
1737
1738 # WiFi power saving mode: on=enable, off=disable; not supported by all adapters.
1739 WIFI_PWR_ON_AC=off
1740 WIFI_PWR_ON_BAT=on
1741
1742 # Disable wake on LAN: Y/N.
1743 WOL_DISABLE=Y
1744
1745 # Enable audio power saving for Intel HDA, AC97 devices (timeout in secs).
1746 # A value of 0 disables, >=1 enables power saving (recommended: 1).
1747 SOUND_POWER_SAVE_ON_AC=0
1748 SOUND_POWER_SAVE_ON_BAT=0
1749
1750 # Disable controller too (HDA only): Y/N.
1751 SOUND_POWER_SAVE_CONTROLLER=N
1752
1753 # Power off optical drive in UltraBay/MediaBay: 0=disable, 1=enable.
1754 # Drive can be powered on again by releasing (and reinserting) the eject lever
1755 # or by pressing the disc eject button on newer models.
1756 # Note: an UltraBay/MediaBay hard disk is never powered off.
1757 BAY_POWEROFF_ON_AC=0
1758 BAY_POWEROFF_ON_BAT=0
1759 # Optical drive device to power off (default sr0).
1760 BAY_DEVICE="sr0"
1761
1762 # Runtime Power Management for PCI(e) bus devices: on=disable, auto=enable.
1763 RUNTIME_PM_ON_AC=on
1764 RUNTIME_PM_ON_BAT=auto
1765
1766 # Exclude PCI(e) device adresses the following list from Runtime PM
1767 # (separate with spaces). Use lspci to get the adresses (1st column).
1768 #RUNTIME_PM_BLACKLIST="bb:dd.f 11:22.3 44:55.6"
1769 RUNTIME_PM_BLACKLIST="01:00.0"
1770
1771 # Exclude PCI(e) devices assigned to the listed drivers from Runtime PM.
1772 # Default when unconfigured is "amdgpu nouveau nvidia radeon" which
1773 # prevents accidential power-on of dGPU in hybrid graphics setups.
1774 # Use "" to disable the feature completely.
1775 # Separate multiple drivers with spaces.
1776 #RUNTIME_PM_DRIVER_BLACKLIST="amdgpu nouveau nvidia radeon"
1777
1778 # Set to 0 to disable, 1 to enable USB autosuspend feature.
1779 USB_AUTOSUSPEND=1
1780
1781 # Exclude listed devices from USB autosuspend (separate with spaces).
1782 # Use lsusb to get the ids.
1783 # Note: input devices (usbhid) are excluded automatically
1784 #USB_BLACKLIST="1111:2222 3333:4444"
1785
1786 # Bluetooth devices are excluded from USB autosuspend:
1787 # 0=do not exclude, 1=exclude.
1788 USB_BLACKLIST_BTUSB=0
1789
1790 # Phone devices are excluded from USB autosuspend:
1791 # 0=do not exclude, 1=exclude (enable charging).
1792 USB_BLACKLIST_PHONE=0
1793
1794 # Printers are excluded from USB autosuspend:
1795 # 0=do not exclude, 1=exclude.
1796 USB_BLACKLIST_PRINTER=1
1797
1798 # WWAN devices are excluded from USB autosuspend:
1799 # 0=do not exclude, 1=exclude.
1800 USB_BLACKLIST_WWAN=1
1801
1802 # Include listed devices into USB autosuspend even if already excluded
1803 # by the blacklists above (separate with spaces).
1804 # Use lsusb to get the ids.
1805 #USB_WHITELIST="1111:2222 3333:4444"
1806
1807 # Set to 1 to disable autosuspend before shutdown, 0 to do nothing
1808 # (workaround for USB devices that cause shutdown problems).
1809 #USB_AUTOSUSPEND_DISABLE_ON_SHUTDOWN=1
1810
1811 # Restore radio device state (Bluetooth, WiFi, WWAN) from previous shutdown
1812 # on system startup: 0=disable, 1=enable.
1813 # Hint: the parameters DEVICES_TO_DISABLE/ENABLE_ON_STARTUP/SHUTDOWN below
1814 # are ignored when this is enabled!
1815 #RESTORE_DEVICE_STATE_ON_STARTUP=0
1816 RESTORE_DEVICE_STATE_ON_STARTUP=1
1817
1818 # Radio devices to disable on startup: bluetooth, wifi, wwan.
1819 # Separate multiple devices with spaces.
1820 #DEVICES_TO_DISABLE_ON_STARTUP="bluetooth wifi wwan"
1821
1822 # Radio devices to enable on startup: bluetooth, wifi, wwan.
1823 # Separate multiple devices with spaces.
1824 #DEVICES_TO_ENABLE_ON_STARTUP="wifi"
1825
1826 # Radio devices to disable on shutdown: bluetooth, wifi, wwan.
1827 # (workaround for devices that are blocking shutdown).
1828 #DEVICES_TO_DISABLE_ON_SHUTDOWN="bluetooth wifi wwan"
1829
1830 # Radio devices to enable on shutdown: bluetooth, wifi, wwan.
1831 # (to prevent other operating systems from missing radios).
1832 #DEVICES_TO_ENABLE_ON_SHUTDOWN="wwan"
1833
1834 # Radio devices to enable on AC: bluetooth, wifi, wwan.
1835 #DEVICES_TO_ENABLE_ON_AC="bluetooth wifi wwan"
1836
1837 # Radio devices to disable on battery: bluetooth, wifi, wwan.
1838 #DEVICES_TO_DISABLE_ON_BAT="bluetooth wifi wwan"
1839
1840 # Radio devices to disable on battery when not in use (not connected):
1841 # bluetooth, wifi, wwan.
1842 #DEVICES_TO_DISABLE_ON_BAT_NOT_IN_USE="bluetooth wifi wwan"
1843
1844 # Battery charge thresholds (ThinkPad only, tp-smapi or acpi-call kernel module
1845 # required). Charging starts when the remaining capacity falls below the
1846 # START_CHARGE_THRESH value and stops when exceeding the STOP_CHARGE_THRESH value.
1847 # Main / Internal battery (values in %)
1848 #START_CHARGE_THRESH_BAT0=75
1849 #STOP_CHARGE_THRESH_BAT0=80
1850 # Ultrabay / Slice / Replaceable battery (values in %)
1851 #START_CHARGE_THRESH_BAT1=75
1852 #STOP_CHARGE_THRESH_BAT1=80
1853
1854 # Restore charge thresholds when AC is unplugged: 0=disable, 1=enable.
1855 #RESTORE_THRESHOLDS_ON_BAT=1
1856
1857 # ------------------------------------------------------------------------------
1858 # tlp-rdw - Parameters for the radio device wizard
1859 # Possible devices: bluetooth, wifi, wwan.
1860
1861 # Hints:
1862 # - Parameters are disabled by default, remove the leading # to enable them
1863 # - Separate multiple radio devices with spaces
1864
1865 # Radio devices to disable on connect.
1866 #DEVICES_TO_DISABLE_ON_LAN_CONNECT="wifi wwan"
1867 #DEVICES_TO_DISABLE_ON_WIFI_CONNECT="wwan"
1868 #DEVICES_TO_DISABLE_ON_WWAN_CONNECT="wifi"
1869
1870 # Radio devices to enable on disconnect.
1871 #DEVICES_TO_ENABLE_ON_LAN_DISCONNECT="wifi wwan"
1872 #DEVICES_TO_ENABLE_ON_WIFI_DISCONNECT=""
1873 #DEVICES_TO_ENABLE_ON_WWAN_DISCONNECT=""
1874
1875 # Radio devices to enable/disable when docked.
1876 #DEVICES_TO_ENABLE_ON_DOCK=""
1877 #DEVICES_TO_DISABLE_ON_DOCK=""
1878
1879 # Radio devices to enable/disable when undocked.
1880 #DEVICES_TO_ENABLE_ON_UNDOCK="wifi"
1881 #DEVICES_TO_DISABLE_ON_UNDOCK=""
1882 #+end_src
1883